Add location_template check to error condition