defined? instead of respond_to?