Added a function for checking for the existence of a key in a hash