mirror of
https://github.com/renovatebot/renovate.git
synced 2025-01-11 14:36:25 +00:00
Fix Object.assign
This commit is contained in:
parent
7dc2f9b36c
commit
4a65854f2c
4 changed files with 5 additions and 5 deletions
|
@ -36,7 +36,7 @@ module.exports = function init() {
|
|||
},
|
||||
];
|
||||
}
|
||||
const config = Object.assign(defaultConfig, customConfig, cliConfig);
|
||||
const config = Object.assign({}, defaultConfig, customConfig, cliConfig);
|
||||
// Set log level
|
||||
logger.level = config.logLevel;
|
||||
|
||||
|
|
|
@ -42,7 +42,7 @@ function findUpgrades(dependencies) {
|
|||
if (upgrades.length > 0) {
|
||||
logger.verbose(`${dep.depName}: Upgrades = ${JSON.stringify(upgrades)}`);
|
||||
upgrades.forEach((upgrade) => {
|
||||
allDependencyUpgrades.push(Object.assign(dep, upgrade));
|
||||
allDependencyUpgrades.push(Object.assign({}, dep, upgrade));
|
||||
});
|
||||
} else {
|
||||
logger.verbose(`${dep.depName}: No upgrades required`);
|
||||
|
|
|
@ -23,7 +23,7 @@ p.then(() => { // eslint-disable-line promise/always-return
|
|||
});
|
||||
|
||||
function getCascadedConfig(repo, packageFile) {
|
||||
const cascadedConfig = Object.assign(config, repo, packageFile);
|
||||
const cascadedConfig = Object.assign({}, config, repo, packageFile);
|
||||
delete cascadedConfig.repositories;
|
||||
config.logger.verbose(`Cascaded config=${JSON.stringify(cascadedConfig)}`);
|
||||
return cascadedConfig;
|
||||
|
|
|
@ -11,8 +11,8 @@ module.exports = processPackageFile;
|
|||
// This function manages the queue per-package file
|
||||
function processPackageFile(repoName, packageFile, setConfig) {
|
||||
// Initialize globals
|
||||
config = setConfig;
|
||||
logger = config.logger;
|
||||
logger = setConfig.logger;
|
||||
config = Object.assign({}, setConfig);
|
||||
|
||||
// Initialize helpers
|
||||
github.init(config.token, logger);
|
||||
|
|
Loading…
Reference in a new issue