Parse responses based on the type of the response, not ajaxDataType

- prevents bug where WS messages wouldn't be parsed with JSONP enabled

#2768