diff --git a/classes/Config.php b/classes/Config.php index e8598c4..98e4299 100644 --- a/classes/Config.php +++ b/classes/Config.php @@ -29,7 +29,7 @@ class Config implements ArrayAccess public function save(): void { - file_put_contents($this->path, json_encode($this->data)); + file_put_contents($this->path, json_encode($this->data,JSON_PRETTY_PRINT)); } private mixed $data = []; diff --git a/plugins/quagga/plugin.js b/plugins/quagga/plugin.js index 3678bd7..1bff20e 100644 --- a/plugins/quagga/plugin.js +++ b/plugins/quagga/plugin.js @@ -1,3 +1,4 @@ +import {App} from "/assets/App.js"; (async function () { $("#buttons").append(``); $("#restart-quagga").click(function () { @@ -6,7 +7,7 @@ self.prop("disabled", true); (async function () { try { - alert(await JSONRPC.__invoke("restart_quagga")); + alert(await App.RPC.__invoke("quagga::restart")); } finally { setTimeout(() => { self.prop("disabled", false);