Skip to content

Node.js based forum software built for the modern web

fix: closes #14453

Barış Soner Uşaklı597cdb40c04a
diff --git a/src/topics/delete.js b/src/topics/delete.js
index 2016c6ce57..6d8f09406c 100644
--- a/src/topics/delete.js
+++ b/src/topics/delete.js
@@ -232,12 +232,12 @@ module.exports = function (Topics) {
uniqCids.add(String(topic.cid));
}
await db.sortedSetRemoveBulk(bulkRemove);
-
+ const uniqTagsArray = Array.from(uniqTags);
await Topics.updateCategoryTagsCount(
Array.from(uniqCids),
- Array.from(uniqTags)
+ uniqTagsArray
);
- await Topics.updateTagCount(uniqTags);
+ await Topics.updateTagCount(uniqTagsArray);
}
async function reduceCounters(topicsData) {