diff options
Diffstat (limited to 'src/reducers')
-rw-r--r-- | src/reducers/setting.js | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/reducers/setting.js b/src/reducers/setting.js new file mode 100644 index 0000000..735d4fb --- /dev/null +++ b/src/reducers/setting.js @@ -0,0 +1,17 @@ +import actions from '../actions'; + +const defaultState = { + settings: {} +}; + +export default function reducer(state = defaultState, action = {}) { + switch (action.type) { + case actions.SETTING_SET_SETTINGS: + return Object.assign({}, state, { + settings: action.settings, + }); + default: + return state; + } +} + |