removed instances of has_key