Update doc comments
Fix missing return of hash function