16212: Refactors PeopleSelect component used on 'Share' dialog.
[arvados.git] / src / views-components / dialog-forms / create-collection-dialog.ts
index 785be787f92952daaa606a77a1d51bda436f9d27..374b070b22e914f6c9865ab0ca4a770b4b327716 100644 (file)
@@ -14,7 +14,9 @@ export const CreateCollectionDialog = compose(
     reduxForm<CollectionCreateFormDialogData>({
         form: COLLECTION_CREATE_FORM_NAME,
         onSubmit: (data, dispatch) => {
-            dispatch(createCollection(data));
+            // Somehow an extra field called 'files' gets added, copy
+            // the data object to get rid of it.
+            dispatch(createCollection({ ownerUuid: data.ownerUuid, name: data.name, description: data.description }));
         }
     })
 )(DialogCollectionCreate);