added runOnBranchChange event #4108

This commit is contained in:
zadam
2023-11-02 23:26:32 +01:00
parent 0efc42081d
commit 45ed436426
5 changed files with 16 additions and 2 deletions

View File

@@ -10,6 +10,7 @@ const TaskContext = require('../../services/task_context');
const branchService = require("../../services/branches");
const log = require("../../services/log");
const ValidationError = require("../../errors/validation_error");
const eventService = require("../../services/events.js");
/**
* Code in this file deals with moving and cloning branches. The relationship between note and parent note is unique
@@ -144,6 +145,11 @@ function setExpanded(req) {
if (branch) {
branch.isExpanded = !!expanded;
}
eventService.emit(eventService.ENTITY_CHANGED, {
entityName: 'branches',
entity: branch
});
}
}