mentioned method

bool mentioned(
  1. {User? user,
  2. User? byOtherUser}
)

Implementation

bool mentioned({User? user, User? byOtherUser}) {
  if (user == null || byOtherUser == null) {
    return false;
  }

  if (mentionType == MentionType.users) {
    return _containsMentionedUser(user) && byOtherUser.userId != user.userId;
  } else if (mentionType == MentionType.channel) {
    return byOtherUser.userId != user.userId;
  }
  return false;
}