$posts * @property-read int|null $posts_count * * @method static \Illuminate\Database\Eloquent\Builder|Hashtag newModelQuery() * @method static \Illuminate\Database\Eloquent\Builder|Hashtag newQuery() * @method static \Illuminate\Database\Eloquent\Builder|Hashtag query() * @method static \Illuminate\Database\Eloquent\Builder|Hashtag whereCachedCount($value) * @method static \Illuminate\Database\Eloquent\Builder|Hashtag whereCanSearch($value) * @method static \Illuminate\Database\Eloquent\Builder|Hashtag whereCanTrend($value) * @method static \Illuminate\Database\Eloquent\Builder|Hashtag whereCreatedAt($value) * @method static \Illuminate\Database\Eloquent\Builder|Hashtag whereId($value) * @method static \Illuminate\Database\Eloquent\Builder|Hashtag whereIsBanned($value) * @method static \Illuminate\Database\Eloquent\Builder|Hashtag whereIsNsfw($value) * @method static \Illuminate\Database\Eloquent\Builder|Hashtag whereName($value) * @method static \Illuminate\Database\Eloquent\Builder|Hashtag whereSlug($value) * @method static \Illuminate\Database\Eloquent\Builder|Hashtag whereUpdatedAt($value) * * @mixin \Eloquent */ class Hashtag extends Model { public $fillable = ['name', 'slug']; public function posts(): HasManyThrough { return $this->hasManyThrough( Status::class, StatusHashtag::class, 'hashtag_id', 'id', 'id', 'status_id' ); } public function url($suffix = ''): string { return config('routes.hashtag.base').$this->slug.$suffix; } }