-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Improve token's controllers by avoiding unnecessary preloads #2216
Conversation
Pull Request Test Coverage Report for Build c4bf68a1-599a-4cb0-8c6b-39c3ffe124fd
💛 - Coveralls |
83569c4
to
ebb1628
Compare
@@ -5,6 +5,7 @@ | |||
- [#2075](https://github.com/poanetwork/blockscout/pull/2075) - add blocks cache | |||
- [#2151](https://github.com/poanetwork/blockscout/pull/2151) - hide dropdown menu then other networks list is empty | |||
- [#2146](https://github.com/poanetwork/blockscout/pull/2146) - feat: add eth_getLogs rpc endpoint | |||
- [#2216](https://github.com/poanetwork/blockscout/pull/2216) - Improve token's controllers by avoiding unnecessary preloads |
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.
let's move it under Chore
since it only refactors code
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'm not sure it can be considered only refactoring code, all the calls to token_from_address_hash
that have not been changed now ask for (and get in return) a different value.
Motivation
Much like #2111 did for transactions, here a token preload has been made optional to avoid performing it when there is no need to.
NOTE: unlike the mentioned PR here the default is to not perform any preload, because there are more calls that don't need it than those who do (including outside of controllers).
Changelog
Enhancements
All token pages with
type: JSON
will be affected as well as a few other calls outside of controllers.Checklist for your PR
CHANGELOG.md
with this PR