Skip to content

Commit

Permalink
Update SettingGroup.php
Browse files Browse the repository at this point in the history
  • Loading branch information
alexvenga authored Jan 6, 2024
1 parent ea94e9b commit 29261eb
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions src/Models/SettingGroup.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,16 @@
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\HasMany;

/**
* @property int $id
* @property string $slug
* @property string|null $hint
* @property Carbon|null $created_at
* @property Carbon|null $updated_at
* @property-read string $name_human attribute
* @property Setting[] $settings
* @property-read int $settings_count
*/
class SettingGroup extends Model
{
protected $guarded = [];
Expand All @@ -23,10 +33,10 @@ public function getNameHumanAttribute(): string
{
$string = $this->slug;

if (!empty($this->name)) {
return $string . ' (' . $this->name . ')';
if (! empty($this->name)) {
return $string.' ('.$this->name.')';
}

return $string;
}
}
}

0 comments on commit 29261eb

Please sign in to comment.