-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Update profilePage to include timezone #1717
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
Merged
Merged
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
f1d29bc
update myPersonalDetails and personalDetails onyx keys to get timezon…
NikkiWines 4d81cff
style
NikkiWines 38a5364
Merge branch 'master' of github.com:Expensify/Expensify.cash into nik…
NikkiWines d027da0
merge master, update AuthScreens.js to not call fetchTimeZone()
NikkiWines d1daae6
undo change to User.js
NikkiWines f990e66
add semicolons
NikkiWines e7e478e
Merge branch 'master' of github.com:Expensify/Expensify.cash into nik…
NikkiWines 9e34aad
update profilePage to detailsPage
NikkiWines 4ce6b36
make both avatar and name selectable
NikkiWines dd91b65
undo file rename
NikkiWines dd76c01
update priorityMode onyx key
NikkiWines c5fe238
use merge instead of set
NikkiWines 13a35e0
include migration in all requisite areas
NikkiWines 3c22053
Merge branch 'master' of github.com:Expensify/Expensify.cash into nik…
NikkiWines ded3189
remove extra space
NikkiWines File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,33 @@ | ||
| import Onyx from 'react-native-onyx'; | ||
| import _ from 'underscore'; | ||
| import ONYXKEYS from '../../ONYXKEYS'; | ||
|
|
||
| // This migration changes the name of the Onyx key NVP_PRIORITY_MODE from priorityMode to nvp_priorityMode | ||
| export default function () { | ||
| return new Promise((resolve) => { | ||
| // Connect to the old key in Onyx to get the old value of priorityMode | ||
| // then set the new key nvp_priorityMode to hold the old data | ||
| // finally remove the old key by setting the value to null | ||
| const connectionID = Onyx.connect({ | ||
| key: 'priorityMode', | ||
| callback: (oldPriorityMode) => { | ||
| Onyx.disconnect(connectionID); | ||
|
|
||
| // Fail early here because there is nothing to migrate | ||
| if (_.isEmpty(oldPriorityMode)) { | ||
| console.debug('[Migrate Onyx] Skipped migration RenamePriorityModeKey'); | ||
| return resolve(); | ||
| } | ||
|
|
||
| Onyx.multiSet({ | ||
| priorityMode: null, | ||
| [ONYXKEYS.NVP_PRIORITY_MODE]: oldPriorityMode, | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Kinda of unrelated but random thought here is that we should probably not reference |
||
| }) | ||
| .then(() => { | ||
| console.debug('[Migrate Onyx] Ran migration RenamePriorityModeKey'); | ||
| resolve(); | ||
| }); | ||
| }, | ||
| }); | ||
| }); | ||
| } | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.