Skip to content

Commit 1b540ff

Browse files
Allow closing pureV5 tasks without activation
1 parent 9d49bb5 commit 1b540ff

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/services/ChallengeService.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1306,7 +1306,7 @@ async function update (currentUser, challengeId, data, isFull) {
13061306
}
13071307
}
13081308
if (data.status === constants.challengeStatuses.Completed) {
1309-
if (challenge.status !== constants.challengeStatuses.Active) {
1309+
if (!_.get(challenge, 'legacy.pureV5Task') && challenge.status !== constants.challengeStatuses.Active) {
13101310
throw new errors.BadRequestError('You cannot mark a Draft challenge as Completed')
13111311
}
13121312
}

0 commit comments

Comments
 (0)