Skip to content

Commit

Permalink
fix: phpstan
Browse files Browse the repository at this point in the history
  • Loading branch information
SychO9 committed Oct 18, 2023
1 parent 2e0d36f commit 52043a9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions framework/core/src/Discussion/Discussion.php
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ public function hide(?User $actor = null): static
$this->raise(new Hidden($this));

$this->afterSave(function () {
$this->fireCustomModelEvent('hidden', false);
$this->fireModelEvent('hidden', false);
});
}

Expand All @@ -163,7 +163,7 @@ public function restore(): static
$this->raise(new Restored($this));

$this->afterSave(function () {
$this->fireCustomModelEvent('restored', false);
$this->fireModelEvent('restored', false);
});
}

Expand Down
2 changes: 1 addition & 1 deletion framework/core/src/Search/Listener/ModelObserver.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ public function restored(AbstractModel $model): void
private function runIndexJob(AbstractModel $model, string $operation): void
{
if ($this->search->indexable($model)) {
foreach ($this->search->indexers($model) as $indexerClass) {
foreach ($this->search->indexers($model::class) as $indexerClass) {
$queue = property_exists($indexerClass, 'queue') ? $indexerClass::$queue : null;

$this->queue->pushOn($queue, new IndexJob($indexerClass, [$model], $operation));
Expand Down

0 comments on commit 52043a9

Please sign in to comment.