From 4955df3911146baf6f0ea8ba2a3b369932655057 Mon Sep 17 00:00:00 2001 From: syuilo Date: Mon, 7 May 2018 04:26:45 +0900 Subject: oops --- src/services/note/create.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/services/note') diff --git a/src/services/note/create.ts b/src/services/note/create.ts index d68fead5c5..634c2e263d 100644 --- a/src/services/note/create.ts +++ b/src/services/note/create.ts @@ -30,7 +30,7 @@ class NotificationManager { private list: Array<{ user: ILocalUser['_id'], reason: Reason; - }>; + }> = []; constructor(user, note) { this.user = user; @@ -300,10 +300,10 @@ export default async (user: IUser, data: { }); // Append mentions data - if (mentions.length > 0) { + if (mentionedUsers.length > 0) { Note.update({ _id: note._id }, { $set: { - mentions + mentions: mentionedUsers.map(u => u._id) } }); } -- cgit v1.2.3-freya