Skip to content

Commit 7e7d748

Browse files
committed
Defaulting the challenge descriptionFormat
1 parent e0cc722 commit 7e7d748

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/services/ChallengeService.js

+5
Original file line numberDiff line numberDiff line change
@@ -782,6 +782,11 @@ async function createChallenge (currentUser, challenge, userToken) {
782782
// this will need to be updated to associate project terms with a roleId
783783
challenge.terms = await helper.validateChallengeTerms(challenge.terms || [])
784784

785+
// default the descriptionFormat
786+
if (!challenge.descriptionFormat) {
787+
challenge.descriptionFormat = 'markdown'
788+
}
789+
785790
if (challenge.phases && challenge.phases.length > 0) {
786791
challenge.endDate = helper.calculateChallengeEndDate(challenge)
787792
}

0 commit comments

Comments
 (0)