-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Closed
Description
For the delete requests of my API, I like to return 204 (no content) when it succeeds. Usually I would do Response::make('', 204);, and that would work fine. But it seems that when the router goes to morph the response, it turns empty string into a null, which then gets json_encoded to "null", and winds up giving a Malformed JSON error for anything consuming the response.
The request still works, but I'd like to remove the Malformed JSON error. Anyone else ran into this and find a work around?
When I get time after work, I'll look into finding a nice way to check for empty responses, and send in a PR if necessary
Metadata
Metadata
Assignees
Labels
No labels