我正在尝试让 RegistrationFeature 与 twitter 和 facebook auth 一起工作。Twitter 和 Facebook 正在运行,但 RegistrationFeature 似乎不想玩。
这是我得到的回复:
响应状态
错误 CodeRequestBindingExceptionmessageUnable to bind requeststack Trace at ServiceStack.WebHost.Endpoints.RestHandler.GetRequest(IHttpRequest httpReq, IRestPath restPath) at ServiceStack.WebHost.Endpoints.RestHandler.ProcessRequest(IHttpRequest httpReq, IHttpResponse httpRes, String operationName)
这是我在 ConfigureAuth 中的代码:
var appSettings = new AppSettings();
Plugins.Add(new AuthFeature(
() =>
new AuthUserSession(),
new IAuthProvider[] {
new CredentialsAuthProvider(),
new TwitterAuthProvider(appSettings),
new FacebookAuthProvider(appSettings),
new GoogleOpenIdOAuthProvider(appSettings)
}));
Plugins.Add(new RegistrationFeature());
var mongoClient = new MongoClient("mongodb://192.168.0.17");
var server = mongoClient.GetServer();
var db = server.GetDatabase("Sonatribe");
container.Register<IUserAuthRepository>(c =>
new MongoDBAuthRepository(db, true));
有什么我想念的想法吗?