-
Notifications
You must be signed in to change notification settings - Fork 20
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
fix: re-fetch appData on talk hash invalidate #247
Conversation
Signed-off-by: Grigorii K. Shartsev <me@shgk.me>
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.
Can't read it from the code really, so just commenting here:
In case it is not happening already, we should also refetch the data if the desktop client version changed. So that when people update the client they always get newest data.
Do you mean, on any update, even if a talk hash was not changed? |
Signed-off-by: Grigorii K. Shartsev <me@shgk.me>
Signed-off-by: Grigorii K. Shartsev <me@shgk.me>
yes, if the talk client version changes, refetch the data. Maybe at some point we don't expose a feature to specific client versions or something alike. |
Done in the last commit |
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.
Didn't test, but looks good
Signed-off-by: Grigorii K. Shartsev <me@shgk.me>
Small update, also save new desktop client version in the appData on re-fetch |
☑️ Resolves
🖼️ Screenshots
No visual changes
🚧 Tasks
AppData
includescapabilities
anduserMetadata
.Before
appData
was collected on the first login, then persist inlocalStorage
until logout. It makes it invalid on Talk update or Talk settings update.This PR:
appData
appData.service
with functions to re-fetch capabilities and userMetadataAppData
appData
during the Welcome screen, without dirtyexecuteJavascript
in the main processtalkHashStore
with the hash restored withappData
setInitialNextcloudTalkHash
mutation to save initial hashmarkNextcloudTalkHashDirty
mutation to handle invalide hash and relaunch the appPossible scenarios:
Scenario 1 - appData invalidates between launches
Scenario 2 - appData invalidates after the launch
The same
Scenario 3 - old appData before this update
The same. Having now
talkHashDirty
flag considers dirty.Drawbacks and alternative solutions