mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
fix: unintentional object pollution by buildForSelectCategories
This commit is contained in:
@@ -370,7 +370,7 @@ async function getSelectData(cids, fields) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Categories.buildForSelectCategories = function (categories, fields, parentCid) {
|
Categories.buildForSelectCategories = function (categories, fields, parentCid) {
|
||||||
function recursive(category, categoriesData, level, depth) {
|
function recursive({ ...category }, categoriesData, level, depth) {
|
||||||
const bullet = level ? '• ' : '';
|
const bullet = level ? '• ' : '';
|
||||||
category.value = category.cid;
|
category.value = category.cid;
|
||||||
category.level = level;
|
category.level = level;
|
||||||
|
|||||||
Reference in New Issue
Block a user