You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 26, 2021. It is now read-only.
even if I switch to a different user (using flow.runHybridFlow(force: true)), the last authenticated user is not the one silently authenticated when the page reload which makes it impossible to always use the same account if the first one used was not the correct account the user wants to use.
I would to have a way to specify the "credentials" to try during flow.clientViaUserConsent(immediate: true), as I'm able to capture and save the last credentials used.
Otherwise is there a way to "save" the next automatically authenticated user in the same window
Or maybe I'm missing something and in that case I could ask in stack overflow but that is a question rather specific to this package.
The text was updated successfully, but these errors were encountered:
One trick would be to allow to specify the "user_id" during the login (gapi.auth.authorize call in implicit.dart). Unfortunately this parameter cannot be specified in the various api provider. Currently that is exactly what I use (I store the user_id of the last user logged in) to check that the automatic logged in user is the one I expected. That does require accessing the PlusApi though
I get the userId the first time using plus api and store it locally so it works well and I can expect to login with the user I want. The code and demo link is here
The only issue is that the "Welcome back" popup from google+ does not match which is kind of bad so I'll find a way to hide it ;)
For me this is is a must have feature so that I can really make a standalone web app that can automatically sync data after loading with the account I have save previously
I'm not sure I got everything right but in my browser application I use the following code on start:
flow.clientViaUserConsent(immediate: true)
and it seems to always load the first user that was logged in the browser "session". I created a simple webapp here:
https://github.com/alextekartik/dart-test/tree/master/googleapi_auths_test
that can be tested here:
http://gstest.tekartik.com/googleapis_auth_test
even if I switch to a different user (using flow.runHybridFlow(force: true)), the last authenticated user is not the one silently authenticated when the page reload which makes it impossible to always use the same account if the first one used was not the correct account the user wants to use.
I would to have a way to specify the "credentials" to try during flow.clientViaUserConsent(immediate: true), as I'm able to capture and save the last credentials used.
Otherwise is there a way to "save" the next automatically authenticated user in the same window
Or maybe I'm missing something and in that case I could ask in stack overflow but that is a question rather specific to this package.
The text was updated successfully, but these errors were encountered: