Skip to content

Instantly share code, notes, and snippets.

@sontuphan
Created November 27, 2017 03:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sontuphan/fd2b02d35c1ff7f11d9ea86b88f6e649 to your computer and use it in GitHub Desktop.
Save sontuphan/fd2b02d35c1ff7f11d9ea86b88f6e649 to your computer and use it in GitHub Desktop.
function rejectPoL()
public
{
address _owner = msg.sender;
require(existedPoL(_owner));
uint _value = getPoL[_owner].deposit;
bool _success = _owner.send(_value);
if (_success) {
getPoL[_owner].receiver = address(0);
getPoL[_owner].initialBlockNumber = 0;
getPoL[_owner].deposit = 0;
RejectPoL(_owner, _value, true);
} else {
RejectPoL(_owner, _value, false);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment