invoker-community
invoker-community copied to clipboard
MongoDB limit issue
Hey Guys,
Just noticed that Invoker has an issue with models using jenssegers's mongodb driver. It expects that the limit value is an integer. Eloquent doesn't care if it's a string or integer..
OS: darwin Invoker Version: 2.8.0 Laravel Version: 8.69.0 Local project: true PHP Binary: /usr/local/bin/php Route: /project/index?class=App%5CModels%5CVideo&time=1638298343158&project=local-vuSuGotfLMFb5D1KSdNdfm
Error:
MongoDB\Exception\InvalidArgumentException
Expected "limit" option to have type "integer" but found "string"
at /Users/huub/Projects/PlatformOne/Code/backend/vendor/mongodb/mongodb/src/Exception/InvalidArgumentException.php:60
56▕
57▕ $expectedType = $typeString;
58▕ }
59▕
➜ 60▕ return new static(sprintf('Expected %s to have type "%s" but found "%s"', $name, $expectedType, get_debug_type($value)));
61▕ }
62▕ }
63▕
[2m+9 vendor frames [22m
10 phar:/Applications/Invoker.app/Contents/Resources/invoker.phar/src/Actions/IndexResourceAction.php:57
Illuminate\Database\Eloquent\Builder::paginate("10", "page", "1")
11 phar:/Applications/Invoker.app/Contents/Resources/invoker.phar/src/Actions/IndexResourceAction.php:36
_HumbugBoxcd54a32bc978\Invoker\Actions\IndexResourceAction::getEntries()