Commit 473af495 authored by Tom Quirk's avatar Tom Quirk

Fix designUploadMutation's optimistic response

Adds `errors` and `skippedDesigns` keys to the optimistic response
for designUploadMutation.

This resolved console warnings when uploading a design.
parent ad9bec95
......@@ -83,6 +83,8 @@ export const designUploadOptimisticResponse = files => {
designManagementUpload: {
__typename: 'DesignManagementUploadPayload',
designs,
skippedDesigns: [],
errors: [],
},
};
};
......
......@@ -218,6 +218,8 @@ describe('Design management index page', () => {
},
},
],
skippedDesigns: [],
errors: [],
},
},
};
......
......@@ -98,6 +98,8 @@ describe('optimistic responses', () => {
},
},
],
errors: [],
skippedDesigns: [],
},
};
expect(designUploadOptimisticResponse([{ name: 'test' }])).toEqual(expectedResponse);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment