ubiquity / ubiquity-dollar

Ubiquity Dollar (UUSD) smart contracts and user interface.
https://uad.ubq.fi
Apache License 2.0
34 stars 89 forks source link

fix: set last byte to 0 in lib storages #919

Closed rndquu closed 6 months ago

rndquu commented 6 months ago

Resolves https://github.com/sherlock-audit/2023-12-ubiquity-judging/issues/121 (part of https://github.com/ubiquity/ubiquity-dollar/issues/874)

Simply put this is gas optimization that sets the last byte of all storage slots to 0 which somehow optimizes gas usage (you may check https://eips.ethereum.org/EIPS/eip-7201).

I've double checked (on the off chance) all lib storage slots for collisions but everything seems to be fine.

ubiquity-os-deployer[bot] commented 6 months ago
e8f0919
c016c6d
gitcoindev commented 6 months ago

This one is interesting, thank you for mentioning https://eips.ethereum.org/EIPS/eip-7201