Skip to content

Commit

Permalink
RavenDB-21860 cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
karmeli87 authored and arekpalinski committed Mar 20, 2024
1 parent 9182997 commit 7dc98e7
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion src/Raven.Server/Documents/Handlers/BatchHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -716,7 +716,6 @@ protected override long ExecuteCmd(DocumentsOperationContext context)
}
}

//var document = cmd.Document.Clone(context);
var putResult = Database.DocumentsStorage.Put(context, cmd.Id, null, cmd.Document, changeVector: changeVector,
flags: DocumentFlags.FromClusterTransaction);
context.DocumentDatabase.HugeDocuments.AddIfDocIsHuge(cmd.Id, cmd.Document.Size);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -686,7 +686,7 @@ private static unsafe SingleClusterDatabaseCommand ReadCommand<TTransaction>(Tra
foreach (BlittableJsonReaderObject blittableCommand in array)
{
var cmd = JsonDeserializationServer.ClusterTransactionDataCommand(blittableCommand);
cmd.Document = cmd.Document.CloneOnTheSameContext(); // we need to get it out of the array
cmd.Document = cmd.Document?.CloneOnTheSameContext(); // we need to get it out of the array
databaseCommands.Add(cmd);
}

Expand Down

0 comments on commit 7dc98e7

Please sign in to comment.