Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

logout之后再login,await没有返回 #50

Open
lumingyuan opened this issue Jun 12, 2019 · 0 comments
Open

logout之后再login,await没有返回 #50

lumingyuan opened this issue Jun 12, 2019 · 0 comments

Comments

@lumingyuan
Copy link

`- (void)login:(FlutterMethodCall*)call result:(FlutterResult)result {
NSDictionary *user = call.arguments;

[JMSGUser loginWithUsername:user[@"username"] password:user[@"password"] completionHandler:^(id resultObject, NSError *error) {
if (error) {
result([error flutterError]);
return;
}

JMSGUser *myInfo = [JMSGUser myInfo];
// 为了和 Android 行为一致,在登录的时候自动下载缩略图。
[myInfo thumbAvatarData:^(NSData *data, NSString *objectId, NSError *error) {
  // 下载失败也及时返回。
  result(nil);
}];

}];
}`
是因为第二重新登录的时候下载缩略图回调不会调用,所以login接口无限期等待

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant