Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix error code for disabled popular endpoint #4296

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

iBicha
Copy link
Contributor

@iBicha iBicha commented Nov 29, 2023

When visiting /api/v1/popular and popular endpoint is disabled
Before:

500 {"error":"Closed stream"}

After

403 {"error":"Administrator has disabled this endpoint."}

@iBicha iBicha requested a review from a team as a code owner November 29, 2023 02:36
@iBicha iBicha requested review from unixfox and removed request for a team November 29, 2023 02:36
@SamantazFox SamantazFox added the need-testing This feature needs to be deployed and tested to see if it's working, and doesn't break something label Nov 29, 2023
Copy link

This pull request has been automatically marked as stale and will be closed in 30 days because it has not had recent activity and is much likely abandoned or outdated. If you think this pull request is still relevant and applicable, you just have to post a comment and it will be unmarked.

@github-actions github-actions bot added the stale label Feb 27, 2024
@iBicha
Copy link
Contributor Author

iBicha commented Feb 27, 2024

Bump

@github-actions github-actions bot removed the stale label Feb 28, 2024
@iBicha
Copy link
Contributor Author

iBicha commented Apr 1, 2024

I don't know what changed, but /api/v1/popular now returns

400 {"error":"Administrator has disabled this endpoint."}

Closing

@iBicha iBicha closed this Apr 1, 2024
@iBicha iBicha deleted the fix/popular-disabled-error branch April 1, 2024 13:35
@syeopite
Copy link
Member

syeopite commented Apr 1, 2024

The PR should probably still be kept to change the HTTP status code from 400 to 403.

The former doesn't exactly fit for a disabled endpoint

@iBicha iBicha restored the fix/popular-disabled-error branch April 1, 2024 14:00
@iBicha iBicha reopened this Apr 1, 2024
@iBicha
Copy link
Contributor Author

iBicha commented Apr 1, 2024

The PR should probably still be kept to change the HTTP status code from 400 to 403.

The former doesn't exactly fit for a disabled endpoint

Fair - updated PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
need-testing This feature needs to be deployed and tested to see if it's working, and doesn't break something
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants