From 74b34cda9327f865b479b15aad2eb79b981cf2b7 Mon Sep 17 00:00:00 2001 From: Rhys Arkins <rhys@arkins.net> Date: Fri, 7 Sep 2018 08:44:58 +0200 Subject: [PATCH] chore: move updateTypes def --- lib/workers/repository/updates/flatten.js | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/workers/repository/updates/flatten.js b/lib/workers/repository/updates/flatten.js index 702b331683..f41109badc 100644 --- a/lib/workers/repository/updates/flatten.js +++ b/lib/workers/repository/updates/flatten.js @@ -18,6 +18,14 @@ function getUpdateTypeRules(packageRules) { function flattenUpdates(config, packageFiles) { const updates = []; + const updateTypes = [ + 'major', + 'minor', + 'patch', + 'pin', + 'digest', + 'lockFileMaintenance', + ]; for (const [manager, files] of Object.entries(packageFiles)) { const managerConfig = getManagerConfig(config, manager); for (const packageFile of files) { @@ -39,14 +47,6 @@ function flattenUpdates(config, packageFiles) { updateConfig, updateConfig[updateConfig.updateType] ); - const updateTypes = [ - 'major', - 'minor', - 'patch', - 'pin', - 'digest', - 'lockFileMaintenance', - ]; for (const updateType of updateTypes) { delete updateConfig[updateType]; } -- GitLab