Rename edd_has_ajax() to edd_test_ajax_works() and rework the function to perform a more accurate test. #2651