Skip to content

Commit 0e7b7ae

Browse files
Populate phases before posting to kafka on update
1 parent f0453f0 commit 0e7b7ae

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/services/ChallengeService.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1001,6 +1001,10 @@ async function update (currentUser, challengeId, data, userToken, isFull) {
10011001
await attachment.delete()
10021002
}
10031003

1004+
if (challenge.phases && challenge.phases.length > 0) {
1005+
getPhasesAndPopulate(challenge)
1006+
}
1007+
10041008
// post bus event
10051009
await helper.postBusEvent(constants.Topics.ChallengeUpdated, challenge)
10061010
return challenge

0 commit comments

Comments
 (0)