Skip to content

Commit

Permalink
Merge pull request #9294 from margarizaldi/spatie-tags-plugin-optimiz…
Browse files Browse the repository at this point in the history
…e-query

Optimize spatie tags table column query
  • Loading branch information
danharrin authored Oct 26, 2023
2 parents 871b817 + 931bb4d commit 73d6c1c
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,8 @@ public function getState(): array
$type = $this->getType();

if ($this->isAnyTagTypeAllowed()) {
$tags = $record->tags();
/** @phpstan-ignore-next-line */
$tags = $record->tags;
} else {
$tags = $record->tagsWithType($type);
}
Expand Down

0 comments on commit 73d6c1c

Please sign in to comment.