{"size": 620, "ext": "js", "max_stars_repo_path": "scripts/pastEvents.js", "max_stars_repo_name": "starcard-org/yield-delegation", "max_stars_repo_stars_event_min_datetime": "2020-10-15T20:05:51.000Z", "max_stars_repo_stars_event_max_datetime": "2021-10-18T22:30:54.000Z", "max_issues_repo_path": "scripts/pastEvents.js", "max_issues_repo_name": "baby636/yield-delegation", "max_issues_repo_issues_event_min_datetime": "2021-03-16T03:15:11.000Z", "max_issues_repo_issues_event_max_datetime": "2022-02-11T23:19:05.000Z", "max_forks_repo_path": "scripts/pastEvents.js", "max_forks_repo_name": "baby636/yield-delegation", "max_forks_repo_forks_event_min_datetime": "2021-02-20T01:06:07.000Z", "max_forks_repo_forks_event_max_datetime": "2021-07-16T17:21:09.000Z"}
{"max_stars_count": 12, "max_issues_count": 5, "max_forks_count": 3, "avg_line_length": 32.6315789474, "max_line_length": 190, "alphanum_fraction": 0.7209677419}
module.exports = async function main(callback) {
  try {
    const ERC20 =  artifacts.require("ERC20");
    let token = new web3.eth.Contract(ERC20.abi, '0xf1f955016EcbCd7321c7266BccFB96c68ea5E49b');//mainnet RLY token

    let block = await web3.eth.getBlockNumber();


    //from rewards distributor to the YFI YDV
    let events = await token.getPastEvents("Transfer", {filter:{from:'0xFb467828778a6747011c467e1B346D08491Ae353', to:'0x16Ea160214795A67b66a82dbd45161b0b2cBE566'}, fromBlock:block-100000});

    console.log(events);
    callback(0);
  } catch (error) {
    console.error(error);
    callback(1);
  }
}
