-
Notifications
You must be signed in to change notification settings - Fork 159
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
Redirect to private link after log in #1900
Conversation
@@ -29,7 +30,8 @@ export const Store = new Vuex.Store({ | |||
app, | |||
apps, | |||
user, | |||
config | |||
config, | |||
links |
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.
This needs to be it's own module due to vuex-persist. Since we are using modules
in options we can't use reducer to persist only specific states. This would mean the only option of adding it to existing module would be user module which doesn't seem right to me to contain info about private link.
💥 Acceptance tests webUITrashbin failed. Please find the screenshots inside ...https://drone.owncloud.com/owncloud/phoenix/4976/
|
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.
See comments.
I'm a bit worried about the potential race conditions when multiple browser tabs are opened with different private links, while here we only store a single link. I'm not sure if this is a big concern though, need to evaluate the risk.
Would also be good to know what @DeepDiver1975 thinks here
also see #1882 not sure if the persistence layer works in incognito mode ? |
Just tried this - works fine |
128f9bd
to
e422aa6
Compare
💥 Acceptance tests webUITrashbin failed. Please find the screenshots inside ...https://drone.owncloud.com/owncloud/phoenix/4999/
|
💥 Acceptance tests failed. Please find the screenshots inside ...https://drone.owncloud.com/owncloud/phoenix/4999/
|
💥 Acceptance tests failed. Please find the screenshots inside ...https://drone.owncloud.com/owncloud/phoenix/4999/
|
Maybe session storage could help here - https://developer.mozilla.org/en-US/docs/Web/API/Window/sessionStorage Will do some testing with it. This would mean then introducing separate vuex-persist logic for the links module though. |
Are there any other alternatives where we could pass the old link around ? |
I think there aren't. Since we leave Phoenix completely due to the authorisation we need to store it in the storage. Other scenarios would lead to losing the link. |
Added Url to name and default value to null
e422aa6
to
63e79f7
Compare
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.
👍
Description
If login page is triggered after trying to access private link, url of private link gets saved to store and via vuex-persist is persisted during the redirection to different page due to login. After login is successful the redirect to private link is triggered. During that redirection the private link gets deleted from store to allow normal log in later.
Motivation and Context
When users don't get redirected to private link after login it is not only a bug but also could lead to potential confusion when they'd think they landed into the folder and could start throwing items in there which where supposed to be somewhere else.
How Has This Been Tested?
Types of changes
Checklist: