Closed Zyles closed 3 years ago
Hi @Zyles , thanks for reporting. I will check it and get back to here
I haven't checked it yet, but the error responses should be 403 as described here.
Is it the error responses you're referring to @Zyles ?
HTTP status code does not follow REST.
@contactjavas Mohon Maaf,
I think you can solve this by passing a second parameter when instantiating WP_REST_Response() with the value of 403, wherever in your code you return this object with statusCode 403. I tried it locally in my install of your plugin and it seems to work
trims.
Hi @morksinaanab, terimakasih banyak :-) atas sarannya.
They're already implemented & pushed to master. But I can't push it yet to Wp plugin svn.
Those errors now have real 403 http status except jwt_auth_no_auth_header
and jwt_bad_auth_header
. There's problem when I assigned http status 403 to those two.
Btw your Indonesian language is great :)
Terimakasih!
Lumayan.. After living for 9 years in Indonesia, I hope to know the language a little bit :-) Terimakasih buat fix2nya!
The update with this correction will be available soon ?
@cedricDevWP The class-auth.php
file has been updated here on github. But it appears to still be old on the Wordpress Plugins Directory when installing via Wordpress.
I just manually replaced the installed file with the one from here.
Now I get the expected HTTP Response status codes. 👍🏼
Hi Guys, I expect to push minor update to the plugin this week (including the fix for this).
Hi @contactjavas,
did you push the update, or not yet ?
The problem is fixed in the code on GitHub, but it seems like no new release version of the jwt-auth plugin has been published yet on wordpress.org:
It would be good if the GitHub repository would also contain the release tags. There are no tags currently. That will allow users and contributors to identify more quickly which changes are part of which release version.
Hey friends.. sorry for the long wait. I've been focusing on my daily work. Version 2.0.0 has just been released on GitHub and in the WordPress plugins repository. It includes a fix for this issue.
Let me close this issue. Please let me know if you encounter any issues regarding the release. Thanks
Every response, even with an error it uses the status code 200, which is incorrect by rest standards.
Should return the correct status code on errors.