Reviewed User package and invite user optical fix

This commit is contained in:
Inga Kirschnick
2023-03-13 13:29:01 +01:00
parent 7e54d56ed5
commit 646f735ab2
16 changed files with 190 additions and 364 deletions

View File

@ -0,0 +1,23 @@
/*****************************************************************************
* Users *
* Fetch requests for /users routes *
*****************************************************************************/
Requests.users = {};
Requests.users.entity = {};
Requests.users.entity.delete = (userId) => {
let input = `/users/${userId}`;
let init = {
method: 'DELETE'
};
return Requests.JSONfetch(input, init);
}
Requests.users.entity.deleteAvatar = (userId) => {
let input = `/users/${userId}/avatar`;
let init = {
method: 'DELETE'
};
return Requests.JSONfetch(input, init);
}