Skip to content

Commit 2ac3442

Browse files
authored
Merge pull request #2462 from appirio-tech/hotfix/phase_update_on_dashboard_bug
fixed bug on dashboard when updating active phase.
2 parents d23084b + 622db3c commit 2ac3442

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/projects/actions/project.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -421,6 +421,7 @@ export function updateProject(projectId, updatedProps, updateExisting = false) {
421421
export function updatePhase(projectId, phaseId, updatedProps, phaseIndex) {
422422
return (dispatch, getState) => {
423423
const state = getState()
424+
phaseIndex = phaseIndex ? phaseIndex : _.findIndex(state.projectState.phases, { id: phaseId })
424425
const phase = state.projectState.phases[phaseIndex]
425426
const phaseStatusChanged = phase.status !== updatedProps.status
426427
const productId = phase.products[0].id

0 commit comments

Comments
 (0)