From 48e688e514f85b16f362979245a2236ab906b128 Mon Sep 17 00:00:00 2001 From: Laura Hausmann Date: Mon, 16 Dec 2024 21:30:26 +0100 Subject: [PATCH] [backend/drive] Normalize empty / whitespace alt text to null --- Iceshrimp.Backend/Core/Services/DriveService.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Iceshrimp.Backend/Core/Services/DriveService.cs b/Iceshrimp.Backend/Core/Services/DriveService.cs index 929843bf..c2c84d80 100644 --- a/Iceshrimp.Backend/Core/Services/DriveService.cs +++ b/Iceshrimp.Backend/Core/Services/DriveService.cs @@ -39,6 +39,9 @@ public class DriveService( if (logExisting) logger.LogDebug("Storing file {uri} for user {userId}", uri, user.Id); + if (string.IsNullOrWhiteSpace(description)) + description = null; + try { // Do we already have the file?