From 661e60027e71050284a9bccf2985071b18334fb9 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Thu, 14 Feb 2019 19:34:17 -0700 Subject: [PATCH] Update Timeline.vue, fix notification bug --- resources/assets/js/components/Timeline.vue | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/resources/assets/js/components/Timeline.vue b/resources/assets/js/components/Timeline.vue index 347cc4546..c9c19c4b2 100644 --- a/resources/assets/js/components/Timeline.vue +++ b/resources/assets/js/components/Timeline.vue @@ -450,7 +450,12 @@ fetchNotifications() { axios.get('/api/v1/notifications') .then(res => { - this.notifications = res.data; + this.notifications = res.data.filter(n => { + if(n.type == 'share' && !status) { + return false; + } + return true; + }); $('.notification-card .loader').addClass('d-none'); $('.notification-card .contents').removeClass('d-none'); });