mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Replace throw with revert() in compilation tests
This commit is contained in:
committed by
chriseth
parent
aa08460d94
commit
bdac82ecdb
@@ -33,18 +33,18 @@ contract PullPayment {
|
||||
uint256 payment = payments[payee];
|
||||
|
||||
if (payment == 0) {
|
||||
throw;
|
||||
revert();
|
||||
}
|
||||
|
||||
if (address(this).balance < payment) {
|
||||
throw;
|
||||
revert();
|
||||
}
|
||||
|
||||
totalPayments = totalPayments.sub(payment);
|
||||
payments[payee] = 0;
|
||||
|
||||
if (!payee.send(payment)) {
|
||||
throw;
|
||||
revert();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user