Skip to content

Commit b9661ef

Browse files
committed
moved details.challengeId to configurable string
1 parent d3ae844 commit b9661ef

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/projects/detail/components/SimplePlan/components/MilestoneChallengeFooter/MilestoneChallengeFooter.jsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ import _ from 'lodash'
66
import cn from 'classnames'
77
import PT from 'prop-types'
88
import {
9-
WORK_MANAGER_APP
9+
WORK_MANAGER_APP,
10+
CHALLENGE_ID_MAPPING
1011
} from '../../../../../../../src/config/constants'
1112
import './MilestoneChallengeFooter.scss'
1213

@@ -34,7 +35,7 @@ class MilestoneChallengeFooter extends React.Component {
3435
const {
3536
milestone
3637
} = this.props
37-
let challengeIds = _.map(milestone.products, 'details.challengeId')
38+
let challengeIds = _.map(milestone.products, `details.${CHALLENGE_ID_MAPPING}`)
3839
challengeIds = _.filter(challengeIds)
3940
const length = Math.ceil(challengeIds.length/6)
4041

0 commit comments

Comments
 (0)