0

我正在使用 mean.io 并且我基本上已经用另一种也使用护照的策略,passport-fitbit 替换了任何提到 Github 护照策略的内容。据我所知,它应该开箱即用 - 可以这么说。

但是,当我单击 mean.io 演示应用程序中的注册按钮时,我收到以下错误:

Error: no strategy registered under name: fibit
at attempt (/project/node_modules/passport/lib/passport/middleware/authenticate.js:237:37)
at Passport.authenticate (/project/node_modules/passport/lib/passport/middleware/authenticate.js:244:7)
at callbacks (/project/node_modules/express/lib/router/index.js:164:37)
at param (/project/node_modules/express/lib/router/index.js:138:11)
at pass (/project/node_modules/express/lib/router/index.js:145:5)
at Router._dispatch (/project/node_modules/express/lib/router/index.js:173:5)
at Object.router (/project/node_modules/express/lib/router/index.js:33:10)
at next (/project/node_modules/express/node_modules/connect/lib/proto.js:193:15)
at Object.handle (/project/node_modules/connect-flash/lib/flash.js:21:5)
at Context.next (/project/node_modules/express/node_modules/connect/lib/proto.js:193:15)

有人有想法么?

4

1 回答 1

0

您没有显示任何代码,但根据错误消息,您似乎在某处拼错了“fitbit”。错误消息引用了未注册的名称“fibit”(缺少第一个“t”)。在您的代码中搜索“fibit”并替换为“fitbit”,然后重试。

于 2014-02-18T03:22:25.443 回答