update hash.