Skip to content
This repository was archived by the owner on Dec 12, 2021. It is now read-only.

Commit 1ba85c1

Browse files
Merge pull request #9 from manavo/patch-1
Fix deleting
2 parents d38df6d + e451ff0 commit 1ba85c1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Engines/TypesenseSearchEngine.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ function (Model $model) {
6161
try {
6262
$this->typesense->deleteDocument(
6363
$collectionIndex,
64-
$model->{$model->getKey()}
64+
$model->getScoutKey()
6565
);
6666
} catch (ObjectNotFound $e) {
6767
// Don't need to do anything here. The object wasn't found anyway, so nothing to delete!
@@ -198,4 +198,4 @@ public function flush($model): void
198198
$collection->delete();
199199
}
200200

201-
}
201+
}

0 commit comments

Comments
 (0)