fix: hide actions when favorited
This commit is contained in:
parent
901693ef16
commit
414793f5eb
|
@ -53,12 +53,12 @@ export default function ChatRightUsers() {
|
||||||
if (!isAnonymous && !isSelf) {
|
if (!isAnonymous && !isSelf) {
|
||||||
if (hasFriendship) {
|
if (hasFriendship) {
|
||||||
if ('active' === friendship[index].status) {
|
if ('active' === friendship[index].status) {
|
||||||
|
if (-1 === favoriteUsers.indexOf(username)) {
|
||||||
userActions.push({
|
userActions.push({
|
||||||
icon: '🚫',
|
icon: '🚫',
|
||||||
label: 'Unfriend',
|
label: 'Unfriend',
|
||||||
onClick: () => dispatch(submitRemoveFriend(id)),
|
onClick: () => dispatch(submitRemoveFriend(id)),
|
||||||
});
|
});
|
||||||
if (-1 === favoriteUsers.indexOf(username)) {
|
|
||||||
userActions.push({
|
userActions.push({
|
||||||
icon: '❤️',
|
icon: '❤️',
|
||||||
label: 'Favorite',
|
label: 'Favorite',
|
||||||
|
@ -105,7 +105,7 @@ export default function ChatRightUsers() {
|
||||||
onClick: () => dispatch(submitUnblock(id)),
|
onClick: () => dispatch(submitUnblock(id)),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
else {
|
else if (-1 === favoriteUsers.indexOf(username)) {
|
||||||
userActions.push({
|
userActions.push({
|
||||||
icon: '☢️',
|
icon: '☢️',
|
||||||
label: 'Block',
|
label: 'Block',
|
||||||
|
|
Loading…
Reference in New Issue
Block a user