getUserInfoByUserAccount method Null safety

Future<UserInfo> getUserInfoByUserAccount(
  1. String userAccount

Gets the user information by passing in the user account.

After a remote user joins the channel, the SDK gets the user ID and user account of the remote user, caches them in a mapping table object (UserInfo), and triggers the RtcEngineEventHandler.userInfoUpdated callback on the local client.

After receiving the RtcEngineEventHandler.userInfoUpdated callback, you can call this method to get the user ID of the remote user from the UserInfo object by passing in the user account.

Parameter userAccount The user account of the user. Ensure that you set this parameter.



Future<UserInfo> getUserInfoByUserAccount(String userAccount) {
  return _invokeMethod('getUserInfoByUserAccount', {
    'userAccount': userAccount,
  }).then((value) {
    return UserInfo.fromJson(Map<String, dynamic>.from(value));