Format code as hexdata

This commit is contained in:
Taylor Gerring
2015-04-02 13:38:12 +02:00
parent b86450aaae
commit 81de8ed091
2 changed files with 6 additions and 1 deletions

View File

@ -325,6 +325,10 @@ func (self *XEth) CodeAt(address string) string {
return common.ToHex(self.State().SafeGet(address).Code())
}
func (self *XEth) CodeAtBytes(address string) []byte {
return self.State().SafeGet(address).Code()
}
func (self *XEth) IsContract(address string) bool {
return len(self.State().SafeGet(address).Code()) > 0
}