translate 5xx to 404 on remote media request

Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
Jason Volk 2025-01-02 00:11:12 +00:00 committed by strawberry
parent b8f8f68634
commit b4ef646485

View file

@ -331,7 +331,10 @@ fn handle_federation_error(
// If we get these from any middleware we'll try the other endpoint rather than // If we get these from any middleware we'll try the other endpoint rather than
// giving up too early. // giving up too early.
if error.status_code().is_client_error() || error.status_code().is_redirection() { if error.status_code().is_redirection()
|| error.status_code().is_client_error()
|| error.status_code().is_server_error()
{
return fallback(); return fallback();
} }