mirror of
https://github.com/linuxserver/core.git
synced 2026-02-20 05:07:19 +08:00
content-type can be undefined
This commit is contained in:
parent
ab562977b5
commit
bdd23d065b
@ -106,9 +106,8 @@ define(function(require, module, exports) {
|
||||
};
|
||||
|
||||
var data = xhr.responseText;
|
||||
if ((options.overrideMimeType || res.headers["content-type"])
|
||||
.indexOf("application/json") === 0
|
||||
) {
|
||||
var contentType = options.overrideMimeType || res.headers["content-type"] || "";
|
||||
if (contentType.indexOf("application/json") === 0) {
|
||||
try {
|
||||
data = JSON.parse(data);
|
||||
} catch (e) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user