Closed kevinrenskers closed 4 years ago
Ah never mind.. the Django server itself has more info:
RuntimeError: You called this URL via POST, but the URL doesn't end in a slash and you have APPEND_SLASH set. Django can't redirect to the slash URL while maintaining POST data. Change your form to point to minotaur.local:8000/api/user/login/ (note the trailing slash), or set APPEND_SLASH=False in your Django settings.
Turns out Django is doing a redirect itself to the URL with the trailing slash, and that is always turned into a GET request. Sigh :)
Is there an option in Squid to always append a trailing slash?
Well using let routes: HttpRoute = ["user", "login", "/"]
solves it, so 🤷
I have a very simple request:
But I get this error:
If I run it with the Charles proxy running, then yea it is actually doing a GET request. If I change
LoginRequest.method
to.put
, the error I get back changes to"Method \"PUT\" not allowed."
.Why is
.post
not actually doing a POST but a GET? 🤔