mirror of
https://github.com/linuxserver/core.git
synced 2026-02-20 05:07:19 +08:00
do not return null from settings.getJSON() since that breaks other plugins
This commit is contained in:
parent
bdd23d065b
commit
a93f7014e6
@ -428,13 +428,13 @@ define(function(require, exports, module) {
|
||||
if (typeof json === "object")
|
||||
return JSON.parse(JSON.stringify(json));
|
||||
|
||||
if (typeof json !== "string")
|
||||
return json;
|
||||
|
||||
try {
|
||||
return JSON.parse(json);
|
||||
if (typeof json === "string") {
|
||||
try {
|
||||
return JSON.parse(json);
|
||||
} catch (e) {}
|
||||
}
|
||||
catch (e) {}
|
||||
// do not return null or undefined so that getJson(query).foo never throws
|
||||
return false;
|
||||
}
|
||||
|
||||
function getBool(query) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user