Changed check_output to check_location for clarity