-
Notifications
You must be signed in to change notification settings - Fork 5k
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
Removing support survey notification from What's New #11118
Conversation
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.
I didn't re-index the translation keys as I didn't want to cause an issue with translations already in progress
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.
If we're going to leave the translation keys as-is, perhaps it would be simpler to leave the notification IDs as-is, and remove #2? Rather than shift them all by one. There is no requirement for them to be consecutive.
Also, we should remove the translations that we're no longer using.
931679c
to
f33a457
Compare
No longer re-indexing notification ids/keys. Good thought to keep it simple. Also, removed the now unused translations |
Builds ready [f33a457]
Page Load Metrics (612 ± 49 ms)
|
app/scripts/migrations/060.js
Outdated
|
||
function transformState(state) { | ||
if ( | ||
state?.NotificationController?.notifications[SUPPORT_NOTIFICATION_KEY] |
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.
Nit: it would be great to have tests for all branches, such as the case where NotificationController
is nullish.
Probably best to add a few more ?.
operators here as well, in case notifications
is nullish, and in case notifications[SUPPORT_NOTIFICATION_KEY]
is nullish. So that this won't crash if the state is invalid.
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.
transformState
updated to accommodate instances where NotificationController
or notifications
are non-existent. Test cases added to cover additional branches
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.
LGTM! Left a few suggestions on making tests more robust.
558eb6a
to
c188bdb
Compare
Builds ready [c188bdb]
Page Load Metrics (623 ± 45 ms)
|
* origin/develop: (227 commits) Improve UI + content for price difference notifications (#11145) Swaps: Create a new swap (#11124) Bump @metamask/controllers from 9.0.0 to 9.1.0 (#11150) Capture exception instead of throw error in useTransactionDisplayData (#11153) Fixing jest component test output errors (#11139) Avoid showing "Gas price extremely low" warning in advanced tab for testnets (#11111) @metamask/[email protected] (#11140) Migrate to new CurrencyRateController (#11005) bump allow scripts (#11134) Show Sentry CLI output when uploading artifacts (#11100) use etherscan-link customBlockExplorer methods with customNetwork usage tracking (#11017) Adding notification for updated seed phrase wording (#11131) Bumping package.json Fix a condition for checking if a token should be added (#11127) Removing support survey notification from What's New (#11118) Handling custom token decimal fetch failure due to network error (#10956) Hide basic tab in advanced gas modal for speedup and cancel when on testnets (#11115) Migrate Sentry settings to environment variables (#11085) Update eth-ledger-bridge-keyring to v0.5.0 (#11064) fix metaRPCClientFactory id handling (#11116) ...
* Removing support notification from what's new * Adding migration for support notification removal * Expanding test cases, using async/await for storage comparison
* Removing support notification from what's new * Adding migration for support notification removal * Expanding test cases, using async/await for storage comparison
Test Plan