Closed phahulin closed 6 years ago
(Refactor)
In function userAddressInfo
userAddressInfo
https://github.com/poanetwork/poa-popa/blob/master/blockchain/contracts/ProofOfPhysicalAddress.sol#L251-L262
it's suggested to use the following check to avoid decoding 0 claim:
0
bytes32 claim = registry.getClaim( address(this), wallet, users[wallet].physicalAddresses[addressIndex].keccakIdentifier); return ( users[wallet].physicalAddresses[addressIndex].name, users[wallet].physicalAddresses[addressIndex].creationBlock, uint256(claim) != 0 ? PhysicalAddressClaim.decodeConfirmation(claim) : 0, users[wallet].physicalAddresses[addressIndex].keccakIdentifier );
(Refactor)
proposal (i.e. no new features or updates, just code optimization/library updates)In function
userAddressInfo
https://github.com/poanetwork/poa-popa/blob/master/blockchain/contracts/ProofOfPhysicalAddress.sol#L251-L262
it's suggested to use the following check to avoid decoding
0
claim: