diff --git a/lib/platform/git/storage.ts b/lib/platform/git/storage.ts
index 95e23c9fb2375fbff082bdb0b1d54d7f5503044d..d50f72c2f21e329ae2d61f73c88706c701dc52ef 100644
--- a/lib/platform/git/storage.ts
+++ b/lib/platform/git/storage.ts
@@ -463,11 +463,11 @@ function checkForPlatformFailure(err: Error) {
     'The remote end hung up unexpectedly',
     'access denied or repository not exported',
   ];
-  platformErrorStrings.forEach(errorStr => {
+  for (const errorStr of platformErrorStrings) {
     if (err.message.includes(errorStr)) {
       throw new Error('platform-error');
     }
-  });
+  }
 }
 
 export default Storage;