resolve hashing bug and fix the record verification function