client/src/reducers/miscReducer.js
author ymh <ymh.work@gmail.com>
Mon, 26 Jun 2017 16:05:47 +0200
changeset 88 2a861fed6bde
parent 72 7634b424f426
child 107 e6f85e26b08c
permissions -rw-r--r--
Deauthenticate user if refresh was not possible (session expired or total delta reached)
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
72
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
     1
import * as types from '../constants/actionTypes';
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
     2
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
     3
export const autoSubmit = (state = false, action) => {
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
     4
  switch (action.type) {
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
     5
    case types.USER_TOGGLE_AUTO_SUBMIT:
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
     6
      return action.value;
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
     7
    default:
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
     8
      return state;
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
     9
  }
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
    10
}
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
    11
7634b424f426 Add checkbox to add not on enter key.
Alexandre Segura <mex.zktk@gmail.com>
parents:
diff changeset
    12