Skip to content

Commit

Permalink
Fixed the bug in the withdrawDone
Browse files Browse the repository at this point in the history
  • Loading branch information
mdranger committed Feb 20, 2020
1 parent 5725f99 commit 8cb58a0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions procwind/asm/SCSProtocolBase.sol
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,10 @@ contract SCSProtocolBase {

function withdraw() public {
if (
scsList[msg.sender].state == uint(SCSStatus.withdrawPending)
scsList[msg.sender].state = uint(SCSStatus.withdrawPending)
&& block.number > (scsList[msg.sender].withdrawBlock + WITHDRAW_BLOCK_DELAY)
) {
scsList[msg.sender].state == uint(SCSStatus.withdrawDone);
scsList[msg.sender].state = uint(SCSStatus.withdrawDone);
scsList[msg.sender].from.transfer(scsList[msg.sender].bond);
}
}
Expand Down
4 changes: 2 additions & 2 deletions procwind/ast/SCSProtocolBase.sol
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,10 @@ contract SCSProtocolBase {

function withdraw() public {
if (
scsList[msg.sender].state == uint(SCSStatus.withdrawPending)
scsList[msg.sender].state = uint(SCSStatus.withdrawPending)
&& block.number > (scsList[msg.sender].withdrawBlock + WITHDRAW_BLOCK_DELAY)
) {
scsList[msg.sender].state == uint(SCSStatus.withdrawDone);
scsList[msg.sender].state = uint(SCSStatus.withdrawDone);
scsList[msg.sender].from.transfer(scsList[msg.sender].bond);
}
}
Expand Down

0 comments on commit 8cb58a0

Please sign in to comment.