summaryrefslogtreecommitdiffstats
path: root/models/activities.js
diff options
context:
space:
mode:
authorJustin Reynolds <justinr1234@gmail.com>2019-06-28 12:52:09 -0500
committerJustin Reynolds <justinr1234@gmail.com>2019-06-28 12:56:51 -0500
commit3eb4d2c341b712268bd321173909e0a7b19a88c9 (patch)
tree25a8fcb088f3984e72a5bd3ded9e6a45376e0693 /models/activities.js
parenta0a482aa8efb3255a523de4524c8e09453d5571f (diff)
downloadwekan-3eb4d2c341b712268bd321173909e0a7b19a88c9.tar.gz
wekan-3eb4d2c341b712268bd321173909e0a7b19a88c9.tar.bz2
wekan-3eb4d2c341b712268bd321173909e0a7b19a88c9.zip
Prettier & eslint project style update
Diffstat (limited to 'models/activities.js')
-rw-r--r--models/activities.js19
1 files changed, 7 insertions, 12 deletions
diff --git a/models/activities.js b/models/activities.js
index 0e158802..e76f3ad1 100644
--- a/models/activities.js
+++ b/models/activities.js
@@ -71,11 +71,6 @@ Activities.after.insert((userId, doc) => {
RulesHelper.executeRules(activity);
});
-Activities.before.update((userId, doc, fieldNames, modifier, options) => {
- modifier.$set = modifier.$set || {};
- modifier.$set.modifiedAt = Date.now();
-});
-
if (Meteor.isServer) {
// For efficiency create indexes on the date of creation, and on the date of
// creation in conjunction with the card or board id, as corresponding views
@@ -87,15 +82,15 @@ if (Meteor.isServer) {
Activities._collection._ensureIndex({ boardId: 1, createdAt: -1 });
Activities._collection._ensureIndex(
{ commentId: 1 },
- { partialFilterExpression: { commentId: { $exists: true } } }
+ { partialFilterExpression: { commentId: { $exists: true } } },
);
Activities._collection._ensureIndex(
{ attachmentId: 1 },
- { partialFilterExpression: { attachmentId: { $exists: true } } }
+ { partialFilterExpression: { attachmentId: { $exists: true } } },
);
Activities._collection._ensureIndex(
{ customFieldId: 1 },
- { partialFilterExpression: { customFieldId: { $exists: true } } }
+ { partialFilterExpression: { customFieldId: { $exists: true } } },
);
// Label activity did not work yet, unable to edit labels when tried this.
//Activities._collection._dropIndex({ labelId: 1 }, { "indexKey": -1 });
@@ -205,20 +200,20 @@ if (Meteor.isServer) {
if (board) {
const watchingUsers = _.pluck(
_.where(board.watchers, { level: 'watching' }),
- 'userId'
+ 'userId',
);
const trackingUsers = _.pluck(
_.where(board.watchers, { level: 'tracking' }),
- 'userId'
+ 'userId',
);
watchers = _.union(
watchers,
watchingUsers,
- _.intersection(participants, trackingUsers)
+ _.intersection(participants, trackingUsers),
);
}
- Notifications.getUsers(watchers).forEach((user) => {
+ Notifications.getUsers(watchers).forEach(user => {
Notifications.notify(user, title, description, params);
});