Use Address.sendValue for PaymentSplitter (#2456)
* use Address.sendValue instead of .transfer * changelog entry Co-authored-by: Hadrien Croubois <hadrien@openzeppelin.com> Co-authored-by: Francisco Giordano <frangio.1@gmail.com>
This commit is contained in:
@ -4,6 +4,7 @@ pragma solidity >=0.6.0 <0.8.0;
|
||||
|
||||
import "../GSN/Context.sol";
|
||||
import "../math/SafeMath.sol";
|
||||
import "../utils/Address.sol";
|
||||
|
||||
/**
|
||||
* @title PaymentSplitter
|
||||
@ -112,7 +113,7 @@ contract PaymentSplitter is Context {
|
||||
_released[account] = _released[account].add(payment);
|
||||
_totalReleased = _totalReleased.add(payment);
|
||||
|
||||
account.transfer(payment);
|
||||
Address.sendValue(account, payment);
|
||||
emit PaymentReleased(account, payment);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user