0.10.2-19 Frontend
This commit is contained in:
@@ -415,6 +415,15 @@ export const api = {
|
||||
method: 'POST'
|
||||
});
|
||||
},
|
||||
async getPref(key) {
|
||||
return request(`/settings/prefs/${encodeURIComponent(key)}`);
|
||||
},
|
||||
async setPref(key, value) {
|
||||
return request(`/settings/prefs/${encodeURIComponent(key)}`, {
|
||||
method: 'PUT',
|
||||
body: JSON.stringify({ value })
|
||||
});
|
||||
},
|
||||
async updateSetting(key, value) {
|
||||
const result = await request(`/settings/${encodeURIComponent(key)}`, {
|
||||
method: 'PUT',
|
||||
|
||||
Reference in New Issue
Block a user