export default function StateHandler() {
  let state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  let action = arguments.length > 1 ? arguments[1] : undefined;
  let data = action.data;

  switch (action.type) {
    case action.type:
      return Object.assign({}, state, {
        data
      });
  }
}