Skip to content

Commit

Permalink
feat: use mapping instead of array for oracle observations
Browse files Browse the repository at this point in the history
  • Loading branch information
xenide committed Jan 22, 2024
1 parent 573a2db commit f7784a2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ReservoirPair.sol
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,7 @@ abstract contract ReservoirPair is IAssetManagedPair, ReservoirERC20 {
string internal constant MAX_CHANGE_RATE_NAME = "Shared::maxChangeRate";
string internal constant ORACLE_CALLER_NAME = "Shared::oracleCaller";

Observation[65_536] internal _observations;
mapping(uint16 => Observation) internal _observations;

// maximum allowed rate of change of price per second
// to mitigate oracle manipulation attacks in the face of post-merge ETH
Expand Down

0 comments on commit f7784a2

Please sign in to comment.