chronicleprotocol / aggor

Oracle aggregator distributing trust among different oracle providers
Other
4 stars 0 forks source link

fix: Adds scaling function to _readTwap #30

Closed jar-o closed 1 month ago

jar-o commented 1 month ago

The _readTwap() function was not performing the proper scaling on the values it received from Uniswap. Aggor uses 8 decimals, and all sources, Chronicles, Chainlink, and Uniswap must conform from their defaults (which all vary) to match. Scaling is a pretty simple and normal pattern in Solidity, and we are employing it elsewhere in Aggor. It simply got missed/lost on the _readTwap() function.

shortcut-integration[bot] commented 1 month ago

This pull request has been linked to Shortcut Story #7267: Aggor deploy by August 2nd.