Skip to content

Instantly share code, notes, and snippets.

@ramyhardan
Last active August 26, 2021 12:59
Show Gist options
  • Save ramyhardan/ca729686bab953ad62cb0f96729b94c5 to your computer and use it in GitHub Desktop.
Save ramyhardan/ca729686bab953ad62cb0f96729b94c5 to your computer and use it in GitHub Desktop.
struct vesting {
uint256 amount;
uint256 startDate;
}
mapping(address => vesting) private _vesting;
function transferVested(
address recipient,
uint256 amount,
uint256 startDate
) public onlyOwner {
...
_vesting[recipient] = vesting(amount, startDate);
emit Vesting(recipient, amount, startDate);
_transfer(owner, recipient, amount);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment