-
Notifications
You must be signed in to change notification settings - Fork 50
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
chore(SpokePool): Remove pre-v3 types and events #663
base: master
Are you sure you want to change the base?
Conversation
These are no longer needed and would potentially otherwise be clobbered by upcoming svm changes. Remove them now to simplify that work.
function depositV2( | ||
address recipient, | ||
address originToken, | ||
uint256 amount, | ||
uint256 destinationChainId, | ||
int64 relayerFeePct, | ||
uint32 quoteTimestamp, | ||
bytes memory message, | ||
uint256 // maxCount | ||
) public payable virtual nonReentrant unpausedDeposits { | ||
// Increment count of deposits so that deposit ID for this spoke pool is unique. | ||
uint32 newDepositId = numberOfDeposits++; | ||
|
||
if (originToken == address(wrappedNativeToken) && msg.value > 0) { | ||
require(msg.value == amount); | ||
wrappedNativeToken.deposit{ value: msg.value }(); | ||
} else IERC20Upgradeable(originToken).safeTransferFrom(msg.sender, address(this), amount); | ||
|
||
emit FundsDeposited( | ||
amount, | ||
chainId(), | ||
destinationChainId, | ||
relayerFeePct, | ||
newDepositId, | ||
quoteTimestamp, | ||
originToken, | ||
recipient, | ||
msg.sender, | ||
message | ||
); | ||
} |
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.
We might want to retain this, tbf.
@mrice32 @nicholaspai Are we OK to move on this cleanup? We have a lot of WIP work that would ideally come after it, but those PRs are instead internalising some overlapping changes. |
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.
Looks good to me
These are no longer needed and would potentially otherwise be clobbered by upcoming svm changes. Remove them now to simplify that work.