From b26d0b6f21f334619b267546c4dbc4c5393e3292 Mon Sep 17 00:00:00 2001 From: mike12345567 Date: Wed, 27 Jul 2022 17:15:01 +0100 Subject: [PATCH] Adding fix for issue in cloud with user password deletion causing undefined errors. --- packages/backend-core/src/middleware/authenticated.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/backend-core/src/middleware/authenticated.js b/packages/backend-core/src/middleware/authenticated.js index 4e6e0b7ba2..d86af773c3 100644 --- a/packages/backend-core/src/middleware/authenticated.js +++ b/packages/backend-core/src/middleware/authenticated.js @@ -127,7 +127,7 @@ module.exports = ( } if (!user && tenantId) { user = { tenantId } - } else { + } else if (user) { delete user.password } // be explicit