updateUserRole method

void updateUserRole(
  1. String userId,
  2. TUIRole role,
  3. RxList<UserModel> destList
)

Implementation

void updateUserRole(String userId, TUIRole role, RxList<UserModel> destList) {
  var index = getUserIndex(userId, destList);
  if (index == -1) {
    return;
  }
  destList[index].userRole.value = role;
}