You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The API has returned an error: TypeError
Status code: 0
Message: Cannot assign string to property App\Dto\SearchCommand::$page of type Spatie\LaravelData\Optional|int
Trace: /var/www/jikan-rest/vendor/spatie/laravel-data/src/Resolvers/DataFromArrayResolver.php on line 49
Expected Behavior
The API should have returned a successful response with data.
I've triaged this. Probably we need to upgrade LaravelData package. There is a PR in LaravelData's repo which might be the solution: spatie/laravel-data#602
Otherwise some global transformer would be required, because all the endpoints are affected by this.
I mean if you set an empty param, you get an error message instead of treating it empty/non-existent.
@nadla20xx For now I can only recommend not passing empty params to the API.
Is there an existing issue for this?
Current Behavior
The API has returned an error:
TypeError
Status code:
0
Message:
Cannot assign string to property App\Dto\SearchCommand::$page of type Spatie\LaravelData\Optional|int
Trace:
/var/www/jikan-rest/vendor/spatie/laravel-data/src/Resolvers/DataFromArrayResolver.php on line 49
Expected Behavior
The API should have returned a successful response with data.
Steps To Reproduce
Http Request: `GET /v4/anime?sfw=&unapproved=&page=&q=&sfw=&genres=&genres_exclude=&letter=&producers=&start_date=2001-01-01&end_date=2010-01-01
Environment
No response
Anything else?
No response
The text was updated successfully, but these errors were encountered: