-
Notifications
You must be signed in to change notification settings - Fork 11
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
ToB improvements #736
ToB improvements #736
Conversation
…’s intended behavior
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.
LGTM
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.
LGTM - just a few questions
@@ -21,7 +21,6 @@ interface IPositionManagerOwnerActions { | |||
* @dev The array of buckets is expected to be constructed off chain by scanning events for that lender. | |||
* @dev The NFT must have already been created, and the number of buckets to be memorialized at a time determined by function caller. | |||
* @dev An additional call is made to the pool to transfer the LPs from their previous owner, to the Position Manager. | |||
* @dev Pool.setPositionOwner() must be called prior to calling this method. |
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 there be some sort of comment pointing to the need to approve the lp transfers?
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.
good point, can you suggest a nice wording for this? And should be applied only when memorializing position, and not for reedemPositions
if I am not wrong?
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.
would this work d58fe44 ?
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.
I actually got this right with 0a50f8e :)
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.
Just saw the request - yeah that looks great!
Ensure that comments in code always reflect the code’s intended behavior.
Deposits.sol#L195
says the following code isCase 1 above
but it’s actually case 2.Pool.sol#L702
says External Functions but is more precisely External View Functions.IPositionManagerOwnerActions.sol#L24
andL54
, the references tosetPositionOwner
are incorrect.Contracts/README.MD#L8
, remove references tocryptopunks
andcrypto kitties
.BorrowerActions#L292
, the comment should read: revert if no amount to pull or repay.Auctions.sol#L1269
, should be removed, astotalBondEscrowed
is updated in the Pool’swithdrawBonds
function.Constant variable WAD is declared but not used in Maths.sol.
Add tests for
Maths.maxInt
andMaths.minInt
In
LenderActions.sol#L185-191
should useBuckets.addLenderLPs
.