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
Looks like having a request body somehow messes with coercion of the path parameter. Using z.coerce.number() instead of z.number() for id works for now. It should work without the explicit coerce according to the PR that added this feature.
The text was updated successfully, but these errors were encountered:
k0l11
changed the title
Path parameters don't get coerced on POST/PATCH/PUT
Path parameters require explicit coerce on POST/PATCH/PUT
Jan 23, 2023
If have the following procedure
and I send the following request
then I get
Looks like having a request body somehow messes with coercion of the path parameter. Using
z.coerce.number()
instead ofz.number()
forid
works for now. It should work without the explicitcoerce
according to the PR that added this feature.The text was updated successfully, but these errors were encountered: