-
Notifications
You must be signed in to change notification settings - Fork 5.4k
refactor: use const for navigate(-1) and navigate('/'); also migrate the remaining files to v5-compat #37819
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
Changes from all commits
8ea37a4
352b27f
20d2209
62fcbcf
15d2ea2
8e8a6d3
f76f9b5
d4ae5ef
dc9beda
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -51,7 +51,7 @@ export default class TransactionListItemDetails extends PureComponent { | |
| senderNickname: PropTypes.string.isRequired, | ||
| transactionStatus: PropTypes.func, | ||
| isCustomNetwork: PropTypes.bool, | ||
| history: PropTypes.object, | ||
| navigate: PropTypes.func.isRequired, | ||
| blockExplorerLinkText: PropTypes.object, | ||
| chainId: PropTypes.string, | ||
| networkConfiguration: PropTypes.object, | ||
|
|
@@ -66,7 +66,7 @@ export default class TransactionListItemDetails extends PureComponent { | |
| transactionGroup: { primaryTransaction }, | ||
| networkConfiguration, | ||
| isCustomNetwork, | ||
| history, | ||
| navigate, | ||
| onClose, | ||
| chainId, | ||
| } = this.props; | ||
|
|
@@ -87,7 +87,7 @@ export default class TransactionListItemDetails extends PureComponent { | |
|
|
||
| if (!rpcPrefs.blockExplorerUrl && isCustomNetwork) { | ||
| onClose(); | ||
| history.push(`${NETWORKS_ROUTE}#blockExplorerUrl`); | ||
| navigate(`${NETWORKS_ROUTE}#blockExplorerUrl`); | ||
cursor[bot] marked this conversation as resolved.
Show resolved
Hide resolved
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. Bug: TransactionListItemDetails crashes due to missing navigate propThe
Contributor
Author
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. The component is already correctly wrapped with |
||
| } else { | ||
| this.context.trackEvent({ | ||
| category: MetaMetricsEventCategory.Transactions, | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.