mirror of
https://github.com/wekan/wekan.git
synced 2025-12-16 15:30:13 +01:00
Merge pull request #3561 from bronger/issue-3133
Changed default behaviour for BIGEVENTS that no activity matches it.
This commit is contained in:
commit
af58b1039e
1 changed files with 12 additions and 10 deletions
|
|
@ -254,17 +254,19 @@ if (Meteor.isServer) {
|
||||||
if (value) params[key] = value;
|
if (value) params[key] = value;
|
||||||
});
|
});
|
||||||
if (board) {
|
if (board) {
|
||||||
const BIGEVENTS = process.env.BIGEVENTS_PATTERN || 'due'; // if environment BIGEVENTS_PATTERN is set or default, any activityType matching it is important
|
const BIGEVENTS = process.env.BIGEVENTS_PATTERN; // if environment BIGEVENTS_PATTERN is set, any activityType matching it is important
|
||||||
try {
|
if (BIGEVENTS) {
|
||||||
const atype = activity.activityType;
|
try {
|
||||||
if (new RegExp(BIGEVENTS).exec(atype)) {
|
const atype = activity.activityType;
|
||||||
watchers = _.union(
|
if (new RegExp(BIGEVENTS).exec(atype)) {
|
||||||
watchers,
|
watchers = _.union(
|
||||||
board.activeMembers().map(member => member.userId),
|
watchers,
|
||||||
); // notify all active members for important events system defined or default to all activity related to due date
|
board.activeMembers().map(member => member.userId),
|
||||||
|
); // notify all active members for important events
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
// passed env var BIGEVENTS_PATTERN is not a valid regex
|
||||||
}
|
}
|
||||||
} catch (e) {
|
|
||||||
// passed env var BIGEVENTS_PATTERN is not a valid regex
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const watchingUsers = _.pluck(
|
const watchingUsers = _.pluck(
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue