1

I have a method that can return data from a struct that might contain a 0 address 0x0000000000000000000000000000000000000000. Is there a way to check for this address using web 3? I know there is web3.isAddress but I would think this would return true for a valid address.

3

Either do a string comparison to "0x0000000000000000000000000000000000000000" or make a BigNumber with it and compare it to zero.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.