aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrenden Bice <brenden.next@gmail.com>2019-04-12 23:09:05 -0400
committerBrenden Bice <brenden.next@gmail.com>2019-04-12 23:09:05 -0400
commit2ae05075758fef79c0a184faf398ddce1617e182 (patch)
treeeb8ea6a1366a89d943dd9459b8d5568967b3e832
parentfa33e3ec58d56a35d276861df761673d7b412696 (diff)
remove error message on no more following
-rw-r--r--src/modules/users.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/modules/users.js b/src/modules/users.js
index cd789f09..934bfd0b 100644
--- a/src/modules/users.js
+++ b/src/modules/users.js
@@ -81,7 +81,8 @@ export const mutations = {
user.friends.push(friend)
}
})
- user.lastFriendId = last(friends).id
+
+ user.lastFriendId = friends.length ? last(friends).id : last(user.friends).id
},
addFollowers (state, { id, followers }) {
const user = state.usersObject[id]