From e553ba2d07ff1b184760db13d638c679b4eadf04 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Mon, 20 Jun 2022 23:38:45 +0200 Subject: [PATCH] fix: account phone internal ids --- app/controllers/api/account.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/controllers/api/account.php b/app/controllers/api/account.php index a9932c1f01..2711b5339e 100644 --- a/app/controllers/api/account.php +++ b/app/controllers/api/account.php @@ -909,6 +909,7 @@ App::post('/v1/account/sessions/phone') $token = new Document([ '$id' => $dbForProject->getId(), 'userId' => $user->getId(), + 'userInternalId' => $user->getInternalId(), 'type' => Auth::TOKEN_TYPE_PHONE, 'secret' => $secret, 'expire' => $expire, @@ -995,6 +996,7 @@ App::put('/v1/account/sessions/phone') [ '$id' => $dbForProject->getId(), 'userId' => $user->getId(), + 'userInternalId' => $user->getInternalId(), 'provider' => Auth::SESSION_PROVIDER_PHONE, 'secret' => Auth::hash($secret), // One way hash encryption to protect DB leak 'expire' => $expiry, @@ -2281,6 +2283,7 @@ App::post('/v1/account/verification/phone') $verification = new Document([ '$id' => $dbForProject->getId(), 'userId' => $user->getId(), + 'userInternalId' => $user->getInternalId(), 'type' => Auth::TOKEN_TYPE_PHONE, 'secret' => $secret, 'expire' => $expire,