diff --git a/reducers/classes.js b/reducers/classes.js index bcd6799..9496b89 100644 --- a/reducers/classes.js +++ b/reducers/classes.js @@ -1,5 +1,5 @@ export default function classes(state) { if (typeof state === "undefined") - return []; + return {}; return state; } diff --git a/reducers/index.js b/reducers/index.js index 509d9a2..5cc5567 100644 --- a/reducers/index.js +++ b/reducers/index.js @@ -2,10 +2,12 @@ import { combineReducers } from "redux"; import timetable from "./timetable"; import classes from "./classes"; +import subjects from "./subjects"; const rootReducer = combineReducers({ timetable, - classes + classes, + subjects, }); export default rootReducer; diff --git a/reducers/subjects.js b/reducers/subjects.js new file mode 100644 index 0000000..ebf2956 --- /dev/null +++ b/reducers/subjects.js @@ -0,0 +1,5 @@ +export default function subjects(state) { + if (typeof state === "undefined") + return []; + return state; +}