Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit 891598a

Browse files
author
James Cori
committed
Can't Close a Draft Challenge
1 parent f3544e0 commit 891598a

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

services/IssueService.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -526,13 +526,13 @@ async function handleIssueClose(event, issue) { // eslint-disable-line
526526
}
527527

528528
// activate challenge
529-
530-
// if (challenge.status === 'Draft') {
531-
// await topcoderApiHelper.activateChallenge(dbIssue.challengeUUID);
529+
530+
if (challenge.status === 'Draft') {
531+
await topcoderApiHelper.activateChallenge(dbIssue.challengeUUID);
532532
//HACK - sleep 30 seconds so the legacy processor has time to "catch up"
533533
// logger.debugWithContext('Sleeping for 1 seconds after activation so everything propagates...', event, issue);
534534
// await new Promise(resolve => setTimeout(resolve, 1000));
535-
// }
535+
}
536536

537537
logger.debugWithContext(`Closing challenge with winner ${assigneeMember.topcoderUsername}(${winnerId})`, event, issue);
538538
await topcoderApiHelper.closeChallenge(dbIssue.challengeUUID, winnerId, assigneeMember.topcoderUsername);

0 commit comments

Comments
 (0)