-
Notifications
You must be signed in to change notification settings - Fork 34
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
Liquidity manager tokens and transfer tokens check #859
Liquidity manager tokens and transfer tokens check #859
Conversation
I see you updated files related to |
cef2042
to
2f61c07
Compare
…r-tokens-check-missing
…r-tokens-check-missing
l2Token, err := l2GatewayWrapper.CalculateL2TokenAddress(nil, l1Token) | ||
if err != nil { | ||
return nil, fmt.Errorf("get local token from liquidityManager: %w", err) | ||
} |
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.
This might change when we flatten everything and the LM is no longer powering a single i_localToken
right? The call to l1Token, err := l1LiquidityManager.ILocalToken(nil)
above might return a list of tokens
…r-tokens-check-missing
Motivation
The
GetTransfers()
functions (bridges), are lacking checks that the L1 and L2 liquidity manager tokens match the addresses provided asremoteToken
andlocalToken
.Solution
Get liquidity managers token in bridge constructor and save for reuse, upon calls to
GetTransfer()
use the address to compare withremoteToken
andlocalToken
.