-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: refactor #13
feat: refactor #13
Conversation
d95b6d9
to
e3e0ee2
Compare
I advise removing payable modifiers from functions since some peripheral contract use multi-delegate call. |
fb49cca
to
11ec2c0
Compare
11ec2c0
to
a9196ef
Compare
c93d56b
to
b841b15
Compare
…ble with Uniswap tests
v3.4.1-solc-0.7-2
…ve sufficient balance after the callback
…l-known tokens on the Ronin network
(token0, token1, fee, tickSpacing) = (token0_, token1_, fee_, tickSpacing_); | ||
// cache these immutable addresses for gas savings when swaps, mints, or burns are performed | ||
governance = IKatanaV3Factory(factory_).owner(); | ||
positionManager = IKatanaGovernance(governance).getPositionManager(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Risk) Potential async risk when changing Governance or Position Manager address
Changing the governance or positionManager address in the factory (since it is upgradable) introduces a risk. It may break contract assumptions, affecting governance minting, swapping, and flash functionalities. If this occurs, the upgrade would also require updates to all active pools.
This known risk is documented here for future reference and should be formally addressed in documentation to prevent mistakes in future operations.
@@ -749,6 +734,11 @@ contract KatanaV3Pool is IKatanaV3Pool { | |||
require(balance1Before.add(uint256(amount1)) <= balance1(), "IIA"); | |||
} | |||
|
|||
// transfer protocol fees to the treasury | |||
if (state.protocolFee > 0) { | |||
TransferHelper.safeTransfer(tokenIn, IKatanaV3Factory(factory).treasury(), state.protocolFee); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should it also emit Collect
event here or a new type of event (optional) ?
Description
Checklist