20 lines
649 B
JavaScript
Raw Normal View History

2023-03-29 14:32:35 +02:00
/*****************************************************************************
2023-10-04 12:32:27 +02:00
* Requests for /admin routes *
2023-03-29 14:32:35 +02:00
*****************************************************************************/
nopaque.requests.admin = {};
2023-03-29 14:32:35 +02:00
nopaque.requests.admin.users = {};
2023-03-29 14:32:35 +02:00
nopaque.requests.admin.users.entity = {};
2023-03-29 14:32:35 +02:00
nopaque.requests.admin.users.entity.confirmed = {};
2023-03-29 14:32:35 +02:00
nopaque.requests.admin.users.entity.confirmed.update = (userId, value) => {
2023-03-29 14:32:35 +02:00
let input = `/admin/users/${userId}/confirmed`;
let init = {
method: 'PUT',
body: JSON.stringify(value)
};
return nopaque.requests.JSONfetch(input, init);
2023-03-29 14:32:35 +02:00
};