Skip to content

Commit

Permalink
Update.
Browse files Browse the repository at this point in the history
  • Loading branch information
lumenwrites committed Nov 21, 2017
1 parent a2badb8 commit 8968999
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion client/build/client.js
Original file line number Diff line number Diff line change
Expand Up @@ -57410,7 +57410,7 @@ exports.default = function () {
var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : INITIAL_STATE;
var action = arguments[1];

var habitList = JSON.parse(JSON.stringify(state.habitList)); /* deep copy */
var habitList = JSON.parse(JSON.stringify(state.habitList)) || []; /* deep copy */

switch (action.type) {
case 'CREATE_HABIT':
Expand Down
2 changes: 1 addition & 1 deletion client/reducers/habits.reducers.js
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ INITIAL_STATE = {

/* Create and modify state. Passing initial state and actions. */
export default function (state = INITIAL_STATE, action) {
var habitList = JSON.parse(JSON.stringify(state.habitList)) /* deep copy */
var habitList = JSON.parse(JSON.stringify(state.habitList)) || [] /* deep copy */

switch (action.type) {
case 'CREATE_HABIT':
Expand Down

0 comments on commit 8968999

Please sign in to comment.