Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
issue with params not actually being passed via UserSession constructor #22
in the example app, the params for UserSessionsController#create are processed via
@user_session = UserSession.new(params[:user_session])
however the form in the example has the params bare. when i change them to be scoped via user_session things break.
I think that's because authlogic connect is not actually using the params passed to UserSession. It looks like it reads the params directly from the controller here:
This comment has been minimized.
This comment has been minimized.Show comment Hide comment
yeah it seems odd that its being handled in the background as that breaks the interface expected with authlogic. seems like it would be clearer to pass the params through the UserSession constructor... at least expectation and the code in the controller seem to indicate that the call to the constructor would handle the params. otherwise it should just be @user_session = UserSession.new without any arguments. i'm trying to find a way to handle passing login/email/password so we can support traditional login in parallel with oauth/openid.
cool, makes sense. There's a lot to clean up there. After realizing, with oauth, creating a user and "connecting with facebook" (aka creating a session) are basically one thing, I started just creating the user through the session (