Skip to content

Commit

Permalink
Update NotificationCard.vue, fix share notifications
Browse files Browse the repository at this point in the history
  • Loading branch information
dansup committed Mar 25, 2020
1 parent 844566b commit 3cb676b
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions resources/assets/js/components/NotificationCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
</div>
<div v-else-if="n.type == 'share'">
<p class="my-0">
<a :href="n.account.url" class="font-weight-bold text-dark word-break" :title="n.account.username">{{truncate(n.account.username)}}</a> shared your <a class="font-weight-bold" v-bind:href="n.status.reblog.url">post</a>.
<a :href="n.account.url" class="font-weight-bold text-dark word-break" :title="n.account.username">{{truncate(n.account.username)}}</a> shared your <a class="font-weight-bold" v-bind:href="n.status.url">post</a>.
</p>
</div>
<div v-else-if="n.type == 'modlog'">
Expand Down Expand Up @@ -90,12 +90,7 @@
fetchNotifications() {
axios.get('/api/pixelfed/v1/notifications')
.then(res => {
let data = res.data.filter(n => {
if(n.type == 'share' && !status) {
return false;
}
return true;
});
let data = res.data;
let ids = res.data.map(n => n.id);
this.notificationMaxId = Math.min(...ids);
this.notifications = data;
Expand Down

0 comments on commit 3cb676b

Please sign in to comment.