From 790fcf37d223f129640aca20c7e185a26b226cdd Mon Sep 17 00:00:00 2001 From: Henry Jameson Date: Mon, 14 Jan 2019 22:38:37 +0300 Subject: notifications now also undergo some parsing, hypothetically could use MastoAPI notifications, maybe. --- src/modules/users.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/modules/users.js') diff --git a/src/modules/users.js b/src/modules/users.js index adbd37dd..33c02a07 100644 --- a/src/modules/users.js +++ b/src/modules/users.js @@ -68,6 +68,7 @@ export const mutations = { }, setUserForNotification (state, notification) { notification.action.user = state.usersObject[notification.action.user.id] + notification.from_profile = state.usersObject[notification.action.user.id] }, setColor (state, { user: { id }, highlighted }) { const user = state.usersObject[id] @@ -149,8 +150,8 @@ const users = { }) }, addNewNotifications (store, { notifications }) { - const users = compact(map(notifications, 'from_profile')) - const notificationIds = compact(notifications.map(_ => String(_.id))) + const users = map(notifications, 'from_profile') + const notificationIds = notifications.map(_ => String(_.id)) store.commit('addNewUsers', users) const notificationsObject = store.rootState.statuses.notifications.idStore -- cgit v1.2.3-70-g09d2