(state)
| 44 | export function createStoreConfig(globalConfig, StoreModel) { |
| 45 | StoreModel.config = fn.assign({ |
| 46 | getState(state) { |
| 47 | if (Array.isArray(state)) { |
| 48 | return state.slice() |
| 49 | } else if (fn.isMutableObject(state)) { |
| 50 | return fn.assign({}, state) |
| 51 | } |
| 52 | |
| 53 | return state |
| 54 | }, |
| 55 | setState(currentState, nextState) { |
| 56 | if (fn.isMutableObject(nextState)) { |
| 57 | return fn.assign(currentState, nextState) |
nothing calls this directly
no outgoing calls
no test coverage detected