-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/login with google #8
base: develop
Are you sure you want to change the base?
Conversation
@@ -8,7 +8,8 @@ Space.messaging.Controller.extend(Space.accountsUi, 'LoginController', { | |||
eventSubscriptions() { | |||
return [{ | |||
'Space.accountsUi.LoginRequested': this._onLoginRequested, | |||
'Space.accountsUi.LogoutRequested': this._onLogoutRequested | |||
'Space.accountsUi.LogoutRequested': this._onLogoutRequested, | |||
'Space.accountsUi.LoginWithGoogleRequested': this._onLoginWithGoogleRequested, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would rather keep a single LoginRequested
event and use something like a service
property to distinguish between the various strategies. Same for the failed / succeeded events!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are two concerns with that. Login and account creation are one if the user is logging in with external OAUTH service, and events have different properties.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But there should be one LoginWithServiceRequested event for all services or the solution with one event as you are suggesting.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok then only unify the failure / success events? My concern here is that subscribers need too much detail about the login process otherwise. Imagine you allow login with all different service providers. Then you would need 6 different event handlers although the basic flow (showing errors / login successful) is always the same 😉
No description provided.