diff --git a/app/controllers/api/account.php b/app/controllers/api/account.php index fb5ed7c7b0..0836da424d 100644 --- a/app/controllers/api/account.php +++ b/app/controllers/api/account.php @@ -2366,6 +2366,7 @@ App::delete('/v1/account/sessions') $queueForEvents ->reset() + ->setEvent('users.[userId].sessions.delete') ->setParam('userId', $user->getId()) ->setPayload($response->output($session, Response::MODEL_SESSION)); diff --git a/app/controllers/api/users.php b/app/controllers/api/users.php index 3ab39fbd7d..516454a457 100644 --- a/app/controllers/api/users.php +++ b/app/controllers/api/users.php @@ -1169,6 +1169,7 @@ App::delete('/v1/users/:userId/sessions') $queueForEvents ->reset() + ->setEvent('users.[userId].sessions.delete') ->setParam('userId', $user->getId()) ->setPayload($response->output($user, Response::MODEL_USER)); diff --git a/tests/e2e/Services/Webhooks/WebhooksCustomClientTest.php b/tests/e2e/Services/Webhooks/WebhooksCustomClientTest.php index fa8d13b97a..1539f5fcc7 100644 --- a/tests/e2e/Services/Webhooks/WebhooksCustomClientTest.php +++ b/tests/e2e/Services/Webhooks/WebhooksCustomClientTest.php @@ -347,9 +347,6 @@ class WebhooksCustomClientTest extends Scope $this->assertEquals($accountSession['headers']['status-code'], 204); - // This is very flakey :/ - \sleep(3); - $webhook = $this->getLastRequest(); $signatureKey = $this->getProject()['signatureKey']; $payload = json_encode($webhook['data']);