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
I have an endpoint which either returns an entity or not.
Instead of returning a 404 I would rather return a 204 which isn't treated as error in the frontend, which is good since the absence of the entity is an expected state.
Reading https://huma.rocks/features/response-outputs/ my only seems to be the Status field in the struct, which is dislike.
Any other option for me like a middleware doing if returnValue = nil... ?
The text was updated successfully, but these errors were encountered:
I have an endpoint which either returns an entity or not.
Instead of returning a 404 I would rather return a 204 which isn't treated as error in the frontend, which is good since the absence of the entity is an expected state.
Reading https://huma.rocks/features/response-outputs/ my only seems to be the
Status
field in the struct, which is dislike.Any other option for me like a middleware doing
if returnValue = nil...
?The text was updated successfully, but these errors were encountered: