Skip to content

Commit

Permalink
Fix query
Browse files Browse the repository at this point in the history
  • Loading branch information
CheesyTech committed Jul 3, 2024
1 parent 0315c83 commit 73e9465
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/HasTags.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,8 @@ public function tagsTranslated(string | null $locale = null): MorphToMany
->morphToMany(self::getTagClassName(), $this->getTaggableMorphName(), $this->getTaggableTableName())
->using($this->getPivotModelClassName())
->select('*')
->selectRaw($this->getQuery()->getGrammar()->wrap("name->>{$locale} as name_translated"))
->selectRaw($this->getQuery()->getGrammar()->wrap("slug->>{$locale} as slug_translated"))
->selectRaw($this->getQuery()->getGrammar()->wrap("name->{$locale} as name_translated"))
->selectRaw($this->getQuery()->getGrammar()->wrap("slug->{$locale} as slug_translated"))
->ordered();
}

Expand Down

0 comments on commit 73e9465

Please sign in to comment.