Skip to content

Commit 6a1b6cc

Browse files
committed
more update
1 parent a0212ea commit 6a1b6cc

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

packages/loopring_v3/contracts/impl/UserStakingPool.sol

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,10 @@ contract UserStakingPool is IUserStakingPool, Claimable
122122
total.balance = total.balance.sub(_amount);
123123
user.balance = user.balance.sub(_amount);
124124

125-
numAddresses -= 1;
125+
if (user.balance == 0) {
126+
numAddresses -= 1;
127+
delete stakings[msg.sender];
128+
}
126129

127130
// transfer LRC to user
128131
require(

0 commit comments

Comments
 (0)