Use headers rather than a model property to determine XHR, tidy up