From a04da673fa5725184684dd181b5fae3b2d6be361 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 10 Jun 2022 15:29:18 -0400 Subject: [PATCH] fix: #10690, all uploads in `uploads/files` showing orphaned --- src/posts/uploads.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/posts/uploads.js b/src/posts/uploads.js index 229eaf2cfe..2f7d1a0b2f 100644 --- a/src/posts/uploads.js +++ b/src/posts/uploads.js @@ -89,7 +89,7 @@ module.exports = function (Posts) { filePaths = [filePaths]; } - const keys = filePaths.map(fileObj => `upload:${md5(fileObj.name.replace('-resized', ''))}:pids`); + const keys = filePaths.map(fileObj => `upload:${md5(fileObj.path.replace('-resized', ''))}:pids`); return await Promise.all(keys.map(k => db.getSortedSetRange(k, 0, -1))); };