mirror of
https://github.com/mickael-kerjean/filestash.git
synced 2025-11-02 20:23:32 +08:00
11 lines
299 B
JavaScript
11 lines
299 B
JavaScript
import { http_post, http_get } from "../helpers";
|
|
|
|
export const Admin = {
|
|
login: function(password = "") {
|
|
return http_post("/admin/api/session", { password: password });
|
|
},
|
|
isAdmin: function() {
|
|
return http_get("/admin/api/session").then((res) => res.result);
|
|
},
|
|
};
|