【问题标题】:OAuth Popup in Ember.js errorEmber.js 错误中的 OAuth 弹出窗口
【发布时间】:2015-12-02 05:34:03
【问题描述】:

我使用最新的 ember-cli 创建了一个简单的 ember.js 应用程序。在我调用的一个简单函数中:

OAuth.initialize('my public key');

之后我执行以下代码:

OAuth.popup('twitter').done(function(twitter) {
        console.log(twitter);
    }).fail(function(err) {
        console.log('It didnt Worked');
    });

弹出窗口打开,我可以使用我的 Twitter 帐户登录。然后弹出窗口关闭,但在 javascript 控制台中我看到以下错误:

Could not retrieve methods TypeError: Cannot read property 'split' of undefined
at Object.module.exports.providers_api.generateMethods (http://localhost:8000/oauth.js:573:30)
at http://localhost:8000/oauth.js:967:17
at _fulfilled (http://localhost:8000/oauth.js:6263:54)
at Promise.then.Q.nextTick.self.promiseDispatch.done (http://localhost:8000/oauth.js:6292:30)
at Promise.promise.promiseDispatch (http://localhost:8000/oauth.js:6225:13)
at http://localhost:8000/oauth.js:6033:44
at runSingle (http://localhost:8000/oauth.js:5566:13)
at MessagePort.flush (http://localhost:8000/oauth.js:5554:13)

OAuth 承诺永远不会得到解决。该错误发生在 OAuth.io Javascript SDK 的 oauth.js 中的第 977 行。

我正在使用以下版本:

☮ ember -v
version: 1.13.8
node: 0.12.4
npm: 2.13.4
os: darwin x64
//OAuth installed via bower
OAuth.io: "oauth.io#~0.4.3"

感谢您的帮助

【问题讨论】:

    标签: javascript twitter ember.js ember-cli oauth.io


    【解决方案1】:

    对不起,我的错。该错误不会使弹出功能崩溃并且承诺得到解决。我又一次学到了这个!=这个。真傻。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2018-04-16
      • 1970-01-01
      • 2016-04-09
      • 1970-01-01
      • 2015-10-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多