Fixing crash if checking the details of a hash returns an error instead of null