Fix setting empty field on file rename
[arvados.git] / src / store / collection-panel / collection-panel-reducer.ts
index b4951b81826b14426b72e813eda7e93d14c2f8f6..55829cb5d094b8e4b9dbddd313dffa256f78eb6f 100644 (file)
@@ -16,5 +16,6 @@ const initialState = {
 export const collectionPanelReducer = (state: CollectionPanelState = initialState, action: CollectionPanelAction) =>
     collectionPanelActions.match(action, {
         default: () => state,
+        SET_COLLECTION: (item) => ({ ...state, item }),
         LOAD_COLLECTION_SUCCESS: ({ item }) => ({ ...state, item }),
     });