Help with simple solidity function not returning what I THINK it should.

I was working away and realized that when I passed an address into my function, things didn't work, if I hardcoded the address in, I was fine. I simplified the original function for testing.

My question is why, when I pass in an address, do I get a partial address padded with 0's returned? If I hardcode the address, the function returns the full address..

Using Remix, Metamask & Ganache. I'm sure it's something I'm probably not understanding correctly.. Any help would be greatly appreciated.
function getCountByOwner(address ownerAddress) public view returns(address theowner)
   return ownerAddress;
Run the function in remix passing an address.


returns: 0x45bc60c78a8bef57000000000000000000000000


Sign In or Register to comment.