invidious icon indicating copy to clipboard operation
invidious copied to clipboard

Fix error code for disabled popular endpoint

Open iBicha opened this issue 2 years ago • 5 comments

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

500 {"error":"Closed stream"}

After

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

iBicha avatar Nov 29 '23 02:11 iBicha

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[bot] avatar Feb 27 '24 12:02 github-actions[bot]

Bump

iBicha avatar Feb 27 '24 13:02 iBicha

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

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

Closing

iBicha avatar Apr 01 '24 13:04 iBicha

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

syeopite avatar Apr 01 '24 13:04 syeopite

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

iBicha avatar Apr 01 '24 14:04 iBicha

Thanks for the fix!

SamantazFox avatar Jul 10 '24 20:07 SamantazFox