diff options
author | Daniel Kesselberg <mail@danielkesselberg.de> | 2021-06-16 15:39:03 +0300 |
---|---|---|
committer | Daniel Kesselberg <mail@danielkesselberg.de> | 2021-07-06 23:04:31 +0300 |
commit | 8fb14b5ffa3450b2c2201ff9bb42c589e4a4afb7 (patch) | |
tree | a5b84701a79eca0784c96a87b37bb20127c4ba86 /lib/Controller/AliasesController.php | |
parent | 70ef1726ad78b25db571e4b8096eaaf2fa2d84c2 (diff) |
Add provisioning for aliases
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
Diffstat (limited to 'lib/Controller/AliasesController.php')
-rw-r--r-- | lib/Controller/AliasesController.php | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/Controller/AliasesController.php b/lib/Controller/AliasesController.php index 8c1b49ddc..add3efb5f 100644 --- a/lib/Controller/AliasesController.php +++ b/lib/Controller/AliasesController.php @@ -72,8 +72,8 @@ class AliasesController extends Controller { * @NoAdminRequired * @TrapError */ - public function update() { - throw new NotImplemented(); + public function update(int $id, string $alias, string $aliasName): JSONResponse { + return new JSONResponse($this->aliasService->update($this->currentUserId, $id, $alias, $aliasName)); } /** @@ -84,7 +84,7 @@ class AliasesController extends Controller { * @return JSONResponse */ public function destroy(int $id): JSONResponse { - return new JSONResponse($this->aliasService->delete($id, $this->currentUserId)); + return new JSONResponse($this->aliasService->delete($this->currentUserId, $id)); } /** @@ -116,7 +116,6 @@ class AliasesController extends Controller { * @throws DoesNotExistException */ public function updateSignature(int $id, string $signature = null): JSONResponse { - $this->aliasService->updateSignature($this->currentUserId, $id, $signature); - return new JSONResponse(); + return new JSONResponse($this->aliasService->updateSignature($this->currentUserId, $id, $signature)); } } |