Zondax / filecoin-solidity

Filecoin Solidity API Library
Apache License 2.0
94 stars 43 forks source link

Validate target address is not string format to abort early #200

Closed emmanuelm41 closed 1 year ago

emmanuelm41 commented 1 year ago

We could check if the address passed as argument on target param (non-singleton actors) starts with f or t, and abort early if that is the case. This will help devs that send wrong values.

Something like require(target[0] == 0x70 || ...., "target address should be bytes format")

:link: zboto Link