Skip to content

Node.js based forum software built for the modern web

feat: add filter:categories.copySettingsFrom

Barış Soner Uşaklıd8e4fd4cddf6
diff --git a/src/categories/create.js b/src/categories/create.js
index 93121dc8b9..b5068ff0dc 100644
--- a/src/categories/create.js
+++ b/src/categories/create.js
@@ -170,6 +170,11 @@ module.exports = function (Categories) {
if (copyParent) {
destination.parentCid = source.parentCid || 0;
}
+ await plugins.hooks.fire('filter:categories.copySettingsFrom', {
+ source: source,
+ destination: destination,
+ copyParent: copyParent,
+ });
await db.setObject(`category:${toCid}`, destination);