Altered response to handle non Ajax requests