Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

YakutD's avatar
Level 1

Inertia redirects along with the method

I noticed that Inertia redirects requests from an unauthenticated user to login along with the method! For example, if I make a PUT request to the /test route, which is protected by the auth:sanctum middleware, then Inertia tries to send a PUT request to login instead of a GET. How can I fix this?

0 likes
1 reply
YakutD's avatar
YakutD
OP
Best Answer
Level 1

Ok, seems I need send my form.put() requests on Vue side like form.post() but with form._method: 'PUT'.

Please or to participate in this conversation.