From 45dc1f265e26679bd819d3f94787fb97275877d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20Ovejero?= Date: Tue, 2 Apr 2024 09:16:13 +0200 Subject: [PATCH] test(core): Fix multiple parallel private key checks (no-changelog) --- .../migrations/common/1711390882123-MoveSshKeysToDatabase.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/cli/src/databases/migrations/common/1711390882123-MoveSshKeysToDatabase.ts b/packages/cli/src/databases/migrations/common/1711390882123-MoveSshKeysToDatabase.ts index b02450b3cc4db..d875f4c65a403 100644 --- a/packages/cli/src/databases/migrations/common/1711390882123-MoveSshKeysToDatabase.ts +++ b/packages/cli/src/databases/migrations/common/1711390882123-MoveSshKeysToDatabase.ts @@ -46,6 +46,11 @@ export class MoveSshKeysToDatabase1711390882123 implements ReversibleMigration { return; } + if (!privateKey) { + logger.error(`[${migrationName}] No private key found, skipping`); + return; + } + const value = JSON.stringify({ encryptedPrivateKey: this.cipher.encrypt(privateKey), publicKey,