Skip to content

Commit b4c5dc2

Browse files
committed
fix(slack/onboard-llmo): close modal upon submission
1 parent c37367d commit b4c5dc2

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/support/slack/actions/onboard-llmo-modal.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -653,6 +653,8 @@ export function onboardLLMOModal(lambdaContext) {
653653
return;
654654
}
655655

656+
await ack({ response_action: 'clear' });
657+
656658
log.info('Onboarding request with parameters:', {
657659
brandName,
658660
imsOrgId,
@@ -662,10 +664,6 @@ export function onboardLLMOModal(lambdaContext) {
662664
originalThreadTs,
663665
});
664666

665-
// eslint-disable-next-line max-statements-per-line
666-
await new Promise((resolve) => { setTimeout(resolve, 500); });
667-
await ack();
668-
669667
// Create a slack context for the onboarding process
670668
// Use original channel/thread if available, otherwise fall back to DM
671669
const responseChannel = originalChannel || body.user.id;
@@ -890,7 +888,9 @@ export function updateIMSOrgModal(lambdaContext) {
890888
return;
891889
}
892890

893-
await ack();
891+
await ack({
892+
response_action: 'clear',
893+
});
894894
const responseChannel = originalChannel;
895895
const responseThreadTs = originalThreadTs;
896896
const { Site } = dataAccess;

0 commit comments

Comments
 (0)