mirror of
https://github.com/bitwarden/server.git
synced 2024-11-26 12:55:17 +01:00
update sprocs for denorm. userid on foldercipher
This commit is contained in:
parent
943ef81c06
commit
f9ef519ec0
@ -35,7 +35,7 @@ BEGIN
|
||||
|
||||
IF @FolderId IS NOT NULL
|
||||
BEGIN
|
||||
EXEC [dbo].[FolderCipher_Create] @FolderId, @Id
|
||||
EXEC [dbo].[FolderCipher_Create] @FolderId, @Id, @UserId
|
||||
END
|
||||
|
||||
IF @Favorite = 1
|
||||
|
@ -26,7 +26,7 @@ BEGIN
|
||||
|
||||
IF @FolderId IS NOT NULL AND (@ExistingFolderId IS NULL OR @FolderId != @ExistingFolderId)
|
||||
BEGIN
|
||||
EXEC [dbo].[FolderCipher_Create] @FolderId, @Id
|
||||
EXEC [dbo].[FolderCipher_Create] @FolderId, @Id, @UserId
|
||||
END
|
||||
|
||||
IF @Favorite = 0
|
||||
|
@ -1,6 +1,7 @@
|
||||
CREATE PROCEDURE [dbo].[FolderCipher_Create]
|
||||
@FolderId UNIQUEIDENTIFIER,
|
||||
@CipherId UNIQUEIDENTIFIER
|
||||
@CipherId UNIQUEIDENTIFIER,
|
||||
@UserId UNIQUEIDENTIFIER
|
||||
AS
|
||||
BEGIN
|
||||
SET NOCOUNT ON
|
||||
@ -8,11 +9,13 @@ BEGIN
|
||||
INSERT INTO [dbo].[FolderCipher]
|
||||
(
|
||||
[FolderId],
|
||||
[CipherId]
|
||||
[CipherId],
|
||||
[UserId]
|
||||
)
|
||||
VALUES
|
||||
(
|
||||
@FolderId,
|
||||
@CipherId
|
||||
@CipherId,
|
||||
@UserId
|
||||
)
|
||||
END
|
@ -1,6 +1,7 @@
|
||||
CREATE PROCEDURE [dbo].[FolderCipher_Delete]
|
||||
@FolderId UNIQUEIDENTIFIER,
|
||||
@CipherId UNIQUEIDENTIFIER
|
||||
@CipherId UNIQUEIDENTIFIER,
|
||||
@UserId UNIQUEIDENTIFIER
|
||||
AS
|
||||
BEGIN
|
||||
SET NOCOUNT ON
|
||||
@ -11,4 +12,5 @@ BEGIN
|
||||
WHERE
|
||||
[FolderId] = @FolderId
|
||||
AND [CipherId] = @CipherId
|
||||
AND [UserId] = @UserId
|
||||
END
|
Loading…
Reference in New Issue
Block a user