getName method

String getName({
  1. bool needAlias = true,
})

Implementation

String getName({bool needAlias = true}) {
  if (needAlias && friend != null && (friend!.alias?.isNotEmpty == true)) {
    return friend!.alias!;
  } else if (user.nick?.isNotEmpty == true) {
    return user.nick!;
  } else {
    return user.userId!;
  }
}