diff --git a/lib/platform/github/gh-got-wrapper.js b/lib/platform/github/gh-got-wrapper.js index 878b73af9874807e18bc23e683e3355e5cc91243..14bb191c3b4133fdbbdbd29235ff816622140f6d 100644 --- a/lib/platform/github/gh-got-wrapper.js +++ b/lib/platform/github/gh-got-wrapper.js @@ -188,7 +188,7 @@ get.reset = function reset() { cache = null; cache = {}; // istanbul ignore if - if (stats.requests && stats.requests.length) { + if (stats.requests && stats.requests.length > 1) { logger.info( { rateLimit: stats.rateLimit, @@ -199,8 +199,8 @@ get.reset = function reset() { ); stats.requests.sort(); logger.debug({ requests: stats.requests }, 'All requests'); + stats = {}; } - stats = {}; }; module.exports = get;