Commit 528c7d732181d5b5524373c1b35cd5dbde446f1f
prioritise following over unblocking for feed messages
Matt McKegg committed on 10/18/2017, 8:13:03 AMParent: f673ec400fd6aac5f54664a90b9d9fc631bab957
Files changed
plugs/message/html/render/following.js | changed |
plugs/message/html/render/following.js | ||
---|---|---|
@@ -32,17 +32,20 @@ | ||
32 | 32 | function messageContent (msg) { |
33 | 33 | var following = msg.value.content.following |
34 | 34 | var blocking = msg.value.content.blocking |
35 | 35 | |
36 | - if (typeof blocking === 'boolean') { | |
36 | + if (blocking === true) { | |
37 | 37 | return [ |
38 | - blocking ? i18n('blocked ') : i18n('unblocked '), | |
39 | - api.profile.html.person(msg.value.content.contact) | |
38 | + i18n('blocked '), api.profile.html.person(msg.value.content.contact) | |
40 | 39 | ] |
41 | - } else { | |
40 | + } else if (typeof following === 'boolean') { | |
42 | 41 | return [ |
43 | 42 | following ? i18n('followed ') : i18n('unfollowed '), |
44 | 43 | api.profile.html.person(msg.value.content.contact) |
45 | 44 | ] |
45 | + } else if (blocking === false) { | |
46 | + return [ | |
47 | + i18n('unblocked '), api.profile.html.person(msg.value.content.contact) | |
48 | + ] | |
46 | 49 | } |
47 | 50 | } |
48 | 51 | } |
Built with git-ssb-web