Skip to content
This repository was archived by the owner on Sep 24, 2018. It is now read-only.

Conversation

@danielbachhuber
Copy link
Member

No description provided.

@danielbachhuber danielbachhuber added this to the 2.0 Beta 10 milestone Dec 15, 2015
@danielbachhuber
Copy link
Member Author

@WP-API/amigos #reviewmerge

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@danielbachhuber Would a 403 status code be more accurate here? Even if a user was logged-in they may not have permission to read private posts.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rest_authorization_required_code() returns 401 when the user is logged out, and 403 when the user is logged in?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

401 is basically "if you are not logged in, login and retry, then we'll tell you if you can access this" so I think we are good.

danielbachhuber added a commit that referenced this pull request Dec 15, 2015
Use proper status code when failing to get comments of private post
@danielbachhuber danielbachhuber merged commit 9cfa514 into develop Dec 15, 2015
@danielbachhuber danielbachhuber deleted the fix-comment-get-private-post branch December 15, 2015 17:33
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants