From 4cc1f509acff8d6ff51b9b893d890822665050c1 Mon Sep 17 00:00:00 2001 From: Fabian Becker Date: Thu, 18 Sep 2014 12:48:18 +0000 Subject: [PATCH] Ignore unknown setting keys on import fixes #4059 - Ignore NotFound setting keys --- core/server/data/import/utils.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/core/server/data/import/utils.js b/core/server/data/import/utils.js index 11e5a464ce..82d4b2d498 100644 --- a/core/server/data/import/utils.js +++ b/core/server/data/import/utils.js @@ -265,7 +265,10 @@ utils = { }); ops.push(models.Settings.edit(tableData, _.extend(internal, {transacting: transaction})).catch(function (error) { - return Promise.reject({raw: error, model: 'setting', data: tableData}); + // Ignore NotFound errors + if (!(error instanceof errors.NotFoundError)) { + return Promise.reject({raw: error, model: 'setting', data: tableData}); + } })); return Promise.settle(ops);