Skip to content

Commit

Permalink
Fix: harden challenge files reducer
Browse files Browse the repository at this point in the history
  • Loading branch information
Berkeley Martinez authored and Berkeley Martinez committed Sep 9, 2016
1 parent dff2c4b commit 69f5f57
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion common/app/routes/challenges/redux/reducer.js
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ const filesReducer = handleActions(
[types.savedCodeFound]: (state, { payload: files }) => ({
...files
}),
[types.updateCurrentChallenge]: (state, { payload: challenge }) => {
[types.updateCurrentChallenge]: (state, { payload: challenge = {} }) => {
if (challenge.type === 'mod') {
return challenge.files;
}
Expand Down

0 comments on commit 69f5f57

Please sign in to comment.