v4-periphery
v4-periphery copied to clipboard
FullRange Hook Bug Fixes
Related Issue
- someone can externally call beforeInitialize and overwrite the poolToken
- function _rebalance is public
- fees can easily be yoinked
Description of changes
- add onlyByManager
- rename _rebalance -> rebalance
- rebalance before add liquidity and mint the user the proportional of
liquidity*totalSupply/getLiquidity(poolId)
instead ofliquidity