diff --git a/src/app/user/controllers/SignatureController.php b/src/app/user/controllers/SignatureController.php index c272163aaad4de0dbe66aefc406560a9f06bed72..851b218e3b8c5b366b1dbbe92416cf9095d8f091 100755 --- a/src/app/user/controllers/SignatureController.php +++ b/src/app/user/controllers/SignatureController.php @@ -222,7 +222,8 @@ class SignatureController if ($GLOBALS['id'] != $args['id'] && !PrivilegeController::hasPrivilege(['userId' => $GLOBALS['id'], 'privilege' => 'manage_users'])) { return $response->withStatus(403)->withJson(['errors' => 'Privilege forbidden']); } - if (!UserController::hasRightByUserId(['activeUserId' => $GLOBALS['id'], 'targetUserId' => $args['id']])) { + + if (!UserController::hasRightByUserId(['activeUserId' => $GLOBALS['id'], 'targetUserId' => $args['id']]) && $GLOBALS['id'] !== $args['id']) { return $response->withStatus(403)->withJson(['errors' => 'Privilege forbidden']); }