Skip to content

Commit 48a8de5

Browse files
committed
Fix missing decode/castingAfter on $old
1 parent 0330adf commit 48a8de5

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/Database/Database.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5853,6 +5853,11 @@ public function upsertDocumentsWithIncrease(
58535853

58545854
$old = $chunk[$index]->getOld();
58555855

5856+
if (!$old->isEmpty()) {
5857+
$old = $this->adapter->castingAfter($collection, $old);
5858+
$old = $this->decode($collection, $old);
5859+
}
5860+
58565861
try {
58575862
$onNext && $onNext($doc, $old->isEmpty() ? null : $old);
58585863
} catch (\Throwable $th) {

0 commit comments

Comments
 (0)