Return false if the input hash is not a string

 - This check was accidentally removed from master.