Fix 2 small problems of using undefined hash entries.