From bfc1101ee99efc29665d602930037303c2326199 Mon Sep 17 00:00:00 2001 From: themeteorchef Date: Fri, 13 Jan 2017 11:54:12 -0600 Subject: [PATCH] merge #201 by hand (h/t beauremus) --- imports/modules/document-editor.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/imports/modules/document-editor.js b/imports/modules/document-editor.js index 3c4a6b7..c51c3bf 100644 --- a/imports/modules/document-editor.js +++ b/imports/modules/document-editor.js @@ -17,13 +17,13 @@ const handleUpsert = () => { if (doc && doc._id) upsert._id = doc._id; - upsertDocument.call(upsert, (error, { insertedId }) => { + upsertDocument.call(upsert, (error, response) => { if (error) { Bert.alert(error.reason, 'danger'); } else { component.documentEditorForm.reset(); Bert.alert(confirmation, 'success'); - browserHistory.push(`/documents/${insertedId || doc._id}`); + browserHistory.push(`/documents/${response.insertedId || doc._id}`); } }); }; -- 2.0.0