diff --git a/lib/platform/github/index.js b/lib/platform/github/index.js index 49e52a6c367ba86b16971b8dd62872e5641a2892..94a3ad10f197d8c837bf9b42914cddc5025fa8bc 100644 --- a/lib/platform/github/index.js +++ b/lib/platform/github/index.js @@ -85,10 +85,6 @@ async function initRepo(repoName, token, endpoint, forkMode, forkToken) { logger.debug('Resetting platform config'); // config is used by the platform api itself, not necessary for the app layer to know config = {}; - // This shouldn't be necessary, but occasional strange errors happened until it was added - delete config.issueList; - delete config.prList; - delete config.fileList; get.reset(); config.repoName = repoName; // platformConfig is passed back to the app layer and contains info about the platform they require @@ -130,6 +126,10 @@ async function initRepo(repoName, token, endpoint, forkMode, forkToken) { logger.info({ err, res }, 'Unknown GitHub initRepo error'); throw err; } + // This shouldn't be necessary, but occasional strange errors happened until it was added + delete config.issueList; + delete config.prList; + delete config.fileList; logger.debug('Prefetching prList and fileList'); await Promise.all([getPrList(), getFileList()]); if (forkMode) {