I want to generate a unique hash value based on the current timestamp. I tried to get the current timestamp by block.timestamp
but it gives me the same number every time so my generated hash value is not unique. How do I deal with this?
function generateUniqueHash() public onlyOwner returns (bytes32) {
return keccak256(abi.encodePacked("secret", block.timestamp));
}