mirror of
https://github.com/gtsteffaniak/filebrowser.git
synced 2026-11-26 00:19:41 -05:00
16 lines
354 B
JavaScript
16 lines
354 B
JavaScript
import { fetchURL, fetchJSON } from "./utils";
|
|
import { getApiPath } from "@/utils/url.js";
|
|
|
|
|
|
export function get(property="") {
|
|
const path = getApiPath("api/settings", { property });
|
|
return fetchJSON(path);
|
|
}
|
|
|
|
export async function update(settings) {
|
|
await fetchURL("api/settings", {
|
|
method: "PUT",
|
|
body: JSON.stringify(settings),
|
|
});
|
|
}
|