Open brolund opened 12 years ago
This needs to be decided at the remoteStorage.js level – please don’t decide that in the app itself. Currently you need to log out of apps and storage separately because signing out of one app shouldn’t affect another.
Signing out and switching users is mainly for development purposes, for that you can also use different browsers and incognito instances. The main use case will be one remoteStorage for everything.
Preferably, I'd do this by giving the user an option to go to the remote storage provider and totally exit.
Good point, this could be a general design pattern for unhosted apps: on the log out screen, give people a link to their storage, in case they want to log out of that too. If they don’t want to do that, they can just ignore it.
connecting/disconnecting is no longer handled by the app code in 0.7, it's now entirely done by the widget. this means the app doesn't even get to control (in theory) whether the user is connected or not, and to where.
the app is informed of the session state, which can be anonymous, connected(idle), connected(offline) or connected(busy). when you disconnect you do this on the widget. disconnecting clears all local cache and brings you to a new, empty anonymous session. the app receive an event to indicate that the app went from connected(idle) state to anonymous state.
about the authorizations - there are 4 situations:
as Jan said, this behaviour is independent of whether you disconnect from your storage. and also as you both remarked, it might be useful to remind the user "don't forget to also log out of your storage if you have not already done so", because it will indeed be easy to forget. in fact, facebook capitalizes on that - i often find myself logged in to facebook because sometime earlier that week i used facebook connect somewhere, and you have to log in and then you stay logged in.
On Tue, Aug 28, 2012 at 10:34 AM, Jan-Christoph Borchardt < notifications@github.com> wrote:
Good point, this could be a general design pattern for unhosted apps: on the log out screen, give people a link to their storage, in case they want to log out of that too. If they don’t want to do that, they can just ignore it.
— Reply to this email directly or view it on GitHubhttps://github.com/agical/friendsunhosted/issues/42#issuecomment-8084817.
When logging out today, you are still (somehow, need to investigate) authorized in the remote storage. We need to put in an option somehow for disconnecting to the remote store as well.
Sometimes it is nice to be able to just logout to switch users back and forth, but sometimes I guess it is relevant not to be able to login again just providing the storage id.