mirror of
https://github.com/zhigang1992/devhub.git
synced 2026-06-19 06:36:48 +08:00
Fix default columns not being created
This commit is contained in:
@@ -17,10 +17,10 @@ export const columnsReducer: Reducer<State> = (
|
||||
switch (action.type) {
|
||||
case REHYDRATE as any:
|
||||
return immer(state, draft => {
|
||||
const columns = columnsSelector((action.payload as any) || {})
|
||||
const columns =
|
||||
columnsSelector((action.payload as any) || {}) || draft.columns
|
||||
|
||||
draft.columns = columns || []
|
||||
draft.columns = draft.columns.filter(c => c && c.id)
|
||||
if (columns) draft.columns = columns.filter(c => c && c.id)
|
||||
})
|
||||
case 'ADD_COLUMN':
|
||||
return immer(state, draft => {
|
||||
|
||||
Reference in New Issue
Block a user