File tree Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -110,6 +110,13 @@ abstract contract HyperdriveStorage is MultiTokenStorage {
110110 _governance = _config.governance;
111111 _feeCollector = _config.feeCollector;
112112
113+ if (
114+ _config.fees.curve > 1e18 ||
115+ _config.fees.flat > 1e18 ||
116+ _config.fees.governance > 1e18
117+ ) {
118+ revert Errors.InvalidFeeAmounts ();
119+ }
113120 _curveFee = _config.fees.curve;
114121 _flatFee = _config.fees.flat;
115122 _governanceFee = _config.fees.governance;
Original file line number Diff line number Diff line change @@ -19,6 +19,7 @@ library Errors {
1919 error InvalidInitialSharePrice ();
2020 error InvalidMaturityTime ();
2121 error InvalidPositionDuration ();
22+ error InvalidFeeAmounts ();
2223 error NegativeInterest ();
2324 error OutputLimit ();
2425 error Paused ();
You can’t perform that action at this time.
0 commit comments