From 5d7020faeb3c4b6064da4e7dd7181beac3ad8f96 Mon Sep 17 00:00:00 2001 From: Laura Hausmann Date: Fri, 10 Jan 2025 10:24:47 +0100 Subject: [PATCH] [backend/drive] Don't proxy requests for local emoji --- Iceshrimp.Backend/Controllers/Web/DriveController.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Iceshrimp.Backend/Controllers/Web/DriveController.cs b/Iceshrimp.Backend/Controllers/Web/DriveController.cs index ae7e41c2..73c484b0 100644 --- a/Iceshrimp.Backend/Controllers/Web/DriveController.cs +++ b/Iceshrimp.Backend/Controllers/Web/DriveController.cs @@ -51,7 +51,7 @@ public class DriveController( var emoji = await db.Emojis.FirstOrDefaultAsync(p => p.Id == id) ?? throw GracefulException.NotFound("Emoji not found"); - if (!options.Value.ProxyRemoteMedia) + if (!options.Value.ProxyRemoteMedia || emoji.Host == null) return Redirect(emoji.RawPublicUrl); return await ProxyAsync(emoji.RawPublicUrl, null, null);