loginIM method
手动登录IM
Implementation
@override
Future<NIMResult<void>> loginIM(String accountId, String token,
{NIMLoginOption? option}) async {
isAutoLogin = false;
setUserListener();
NIMLoginOption? innerOption;
if (option == null) {
innerOption = NIMLoginOption();
} else {
innerOption = option;
}
var result = await NimCore.instance.loginService
.login(accountId, token, innerOption);
if (result.isSuccess) {
await syncUserInfo(accountId);
return result;
} else {
return result;
}
}