1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-01-17 14:28:24 +01:00

fix detection of content type for non-native requests

This commit is contained in:
Anton Romanov 2015-08-19 16:18:18 -07:00
parent eaad1f28df
commit 10fc1adf6e

View File

@ -564,7 +564,7 @@ Tomahawk.ajax = function(url, settings) {
contentType = 'application/json';
} else if (contentType === 'xml') {
contentType = 'text/xml';
} else if (xhr.hasOwnProperty('getResponseHeader')) {
} else if (typeof xhr.getResponseHeader !== 'undefined') {
contentType = xhr.getResponseHeader('Content-Type');
} else if (xhr.hasOwnProperty('contentType')) {
contentType = xhr['contentType'];