Fixing sha1 hashing