fix: token details loading, caching, and duplicate modal navigation(OK-52689 OK-52688)#11086
Merged
weatherstar merged 18 commits intoxfrom Apr 8, 2026
Merged
fix: token details loading, caching, and duplicate modal navigation(OK-52689 OK-52688)#11086weatherstar merged 18 commits intoxfrom
weatherstar merged 18 commits intoxfrom
Conversation
Prevent the cached-details useEffect from calling updateTokenMetadata after the fetch promise has already returned real data, avoiding unnecessary re-renders.
Replace polling-based pending modal tracking with a navigation state listener for more efficient and reliable duplicate detection. Also fix findIndex returning undefined when routes is nil.
- Add paramsKey to pending modal target so navigations to the same screen with different params are no longer treated as duplicates - Include currencyInfo.id in token details cache key to avoid showing stale fiat values after currency switch
Contributor
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
originalix
previously approved these changes
Apr 7, 2026
- Remove isLoading prop from TxHistoryListView (not in component IProps) - Derive effectiveInit synchronously to prevent one-frame empty history flash - Add justification comment for 'state' as any cast in useAppNavigation
zhaono1
approved these changes
Apr 8, 2026
huhuanming
approved these changes
Apr 8, 2026
PatrickChoo
pushed a commit
to PatrickChoo/app-monorepo
that referenced
this pull request
Apr 8, 2026
…K-52689 OK-52688) (OneKeyHQ#11086) * fix token details loading and cached values * fix: skip redundant updateTokenMetadata when fetch result exists Prevent the cached-details useEffect from calling updateTokenMetadata after the fetch promise has already returned real data, avoiding unnecessary re-renders. * fix: prevent duplicate modal navigation with state listener dedup Replace polling-based pending modal tracking with a navigation state listener for more efficient and reliable duplicate detection. Also fix findIndex returning undefined when routes is nil. * fix: include params in modal dedupe key and currency in token cache key - Add paramsKey to pending modal target so navigations to the same screen with different params are no longer treated as duplicates - Include currencyInfo.id in token details cache key to avoid showing stale fiat values after currency switch * fix: lint
PatrickChoo
pushed a commit
to PatrickChoo/app-monorepo
that referenced
this pull request
Apr 8, 2026
…K-52689 OK-52688) (OneKeyHQ#11086) * fix token details loading and cached values * fix: skip redundant updateTokenMetadata when fetch result exists Prevent the cached-details useEffect from calling updateTokenMetadata after the fetch promise has already returned real data, avoiding unnecessary re-renders. * fix: prevent duplicate modal navigation with state listener dedup Replace polling-based pending modal tracking with a navigation state listener for more efficient and reliable duplicate detection. Also fix findIndex returning undefined when routes is nil. * fix: include params in modal dedupe key and currency in token cache key - Add paramsKey to pending modal target so navigations to the same screen with different params are no longer treated as duplicates - Include currencyInfo.id in token details cache key to avoid showing stale fiat values after currency switch * fix: lint
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
initResultandisLoadinghandlingupdateTokenMetadatawhen fetch result already existsTest plan