1
0
mirror of https://github.com/bitwarden/server synced 2025-12-30 15:14:02 +00:00

Auth/pm 25453/support n users auth request (#6347)

* fix(pending-auth-request-view): [PM-25453] Bugfix Auth Requests Multiple Users Same Device - fixed view to allow for multiple users for each device when partitioning for the auth request view.
This commit is contained in:
Patrick-Pimentel-Bitwarden
2025-09-17 17:14:00 -04:00
committed by GitHub
parent d83395aeb0
commit 26e574e8d7
2 changed files with 43 additions and 1 deletions

View File

@@ -7,7 +7,7 @@ AS
SELECT
[AR].*,
[D].[Id] AS [DeviceId],
ROW_NUMBER() OVER (PARTITION BY [AR].[RequestDeviceIdentifier] ORDER BY [AR].[CreationDate] DESC) AS [rn]
ROW_NUMBER() OVER (PARTITION BY [AR].[RequestDeviceIdentifier], [AR].[UserId] ORDER BY [AR].[CreationDate] DESC) AS [rn]
FROM [dbo].[AuthRequest] [AR]
LEFT JOIN [dbo].[Device] [D]
ON [AR].[RequestDeviceIdentifier] = [D].[Identifier]