1
0
mirror of https://github.com/bitwarden/server.git synced 2025-06-30 07:36:14 -05:00

[Soft Delete] - Add not null/is null filters to soft delete and restore sprocs

This commit is contained in:
Chad Scharf
2020-04-09 15:25:17 -04:00
parent 4b5e708ea3
commit 32f19e9f90
3 changed files with 139 additions and 1 deletions

View File

@ -21,8 +21,9 @@ BEGIN
[dbo].[UserCipherDetails](@UserId)
WHERE
[Edit] = 1
AND [DeletedDate] IS NOT NULL
AND [Id] IN (SELECT * FROM @Ids)
DECLARE @UtcNow DATETIME2(7) = GETUTCDATE();
UPDATE
[dbo].[Cipher]

View File

@ -21,6 +21,7 @@ BEGIN
[dbo].[UserCipherDetails](@UserId)
WHERE
[Edit] = 1
AND [DeletedDate] IS NULL
AND [Id] IN (SELECT * FROM @Ids)
-- Delete ciphers