From 1e7f32b1c41043f2a196e86d671d1ad848d817dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Soner=20U=C5=9Fakl=C4=B1?= Date: Tue, 14 Mar 2023 14:30:46 -0400 Subject: [PATCH] fix: #11357 clear cache on thumb remove --- src/topics/thumbs.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/topics/thumbs.js b/src/topics/thumbs.js index f2bacf74d3..f6f6a88400 100644 --- a/src/topics/thumbs.js +++ b/src/topics/thumbs.js @@ -151,6 +151,9 @@ Thumbs.delete = async function (id, relativePaths) { Promise.all(toRemove.map(async relativePath => posts.uploads.dissociate(mainPid, relativePath.slice(1)))), ]); } + if (toRemove.length) { + cache.del(set); + } }; Thumbs.deleteAll = async (id) => {