streamline handling of potentially null hashes