Skip to content

Commit

Permalink
[Obs AI Assistant] Fix floating promises
Browse files Browse the repository at this point in the history
  • Loading branch information
viduni94 committed Dec 3, 2024
1 parent cd9d171 commit 03dca8f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ export default function ApiTest({ getService }: FtrProviderContext) {
.set('kbn-xsrf', 'true');

if (payload?.body) {
request.send(payload.body);
await request.send(payload.body);
}

await request.expect(403);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -271,11 +271,11 @@ export default function ApiTest({ getService }: FtrProviderContext) {
.set('kbn-xsrf', 'true');

if (payload?.body) {
request.send(payload.body);
await request.send(payload.body);
}

if (payload?.query) {
request.query(payload.query);
await request.query(payload.query);
}

await request.expect(403).then(({ body }) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -403,11 +403,11 @@ export default function ApiTest({ getService }: FtrProviderContext) {
.set('kbn-xsrf', 'true');

if (payload?.body) {
request.send(payload.body);
await request.send(payload.body);
}

if (payload?.query) {
request.query(payload.query);
await request.query(payload.query);
}

await request.expect(403).then(({ body }) => {
Expand Down

0 comments on commit 03dca8f

Please sign in to comment.