iPhone 上的 facebook 连接 - 拨打电话时出现错误 102“会话密钥无效或不再有效”,但流对话框仍然有效

发布于 2024-08-22 11:52:38 字数 297 浏览 6 评论 0原文

有人看到这个吗?
我遇到的情况是,有时 [sessionresume] 返回 YES。我进行 FBRequest.call,并调用错误委托。 错误为 102“会话密钥无效或不再有效”。 但是,如果在同一会话中我调用任何 FBDialog(例如发布到流),这些都可以正常工作。我不明白为什么他们没有犯同样的错误。

有什么想法吗?

是的。我知道有一个 facebook connect 论坛,但花了很长时间才将我的密码发送给我。 (是的……有一个讽刺之处 - 他们为什么不直接使用 facebook connect 来建立他们的论坛……呵呵)。

Anyone see this?
I've a situation whereby sometimes, [session resume] returns YES. I make a FBRequest.call, and the error delegate gets called.
The error has 102 "Session key invalid or no longer valid".
However, if within the same session I call up any FBDialogs (e.gr. to publish to a stream), these all work fine. I don't see why they are not suffering the same error.

Any ideas?

Yes. I know there's a forum for facebook connect, but its taking an age to get my password sent to me. (Yes...there's an irony there - why didn't they just use facebook connect for their forums...ho hum).

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

心安伴我暖 2024-08-29 11:52:38
- (BOOL)resume {
  NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
  FBUID uid = [[defaults objectForKey:@"FBUserId"] longLongValue];
  if (uid) {
    NSDate* expirationDate = [defaults objectForKey:@"FBSessionExpires"];
    if (!expirationDate || [expirationDate timeIntervalSinceNow] > 0) {
      _uid = uid;
      _sessionKey = [[defaults stringForKey:@"FBSessionKey"] copy];
      _sessionSecret = [[defaults stringForKey:@"FBSessionSecret"] copy];
      _expirationDate = [expirationDate retain];

      for (id<FBSessionDelegate> delegate in _delegates) {
        [delegate session:self didLogin:_uid];
      }
      return YES;
    }
  }
  return NO;
}

这是该方法的代码,我不认为该代码试图与 facebook 建立连接进行测试,他们只是获取过期日期。我认为有时,当你注销 Facebook 时,会话不会过期,但在服务器端,他们会删除你的会话

- (BOOL)resume {
  NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
  FBUID uid = [[defaults objectForKey:@"FBUserId"] longLongValue];
  if (uid) {
    NSDate* expirationDate = [defaults objectForKey:@"FBSessionExpires"];
    if (!expirationDate || [expirationDate timeIntervalSinceNow] > 0) {
      _uid = uid;
      _sessionKey = [[defaults stringForKey:@"FBSessionKey"] copy];
      _sessionSecret = [[defaults stringForKey:@"FBSessionSecret"] copy];
      _expirationDate = [expirationDate retain];

      for (id<FBSessionDelegate> delegate in _delegates) {
        [delegate session:self didLogin:_uid];
      }
      return YES;
    }
  }
  return NO;
}

Here is the code of that method, I don't think that the code is trying to make the connection with facebook to test, they just get the expiration date. I think that sometimes, when you logout of facebook, the session does not expire but on server side, they delete your session

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文