You can define default model data for BelongsTo relationships
- ·
- Telegram
- ·
- Newsletter
🔥 Laravel Tip: Default Models.
In your relationships, you can define default models.
That way if the relationship doesn't exist it will return a default model so you don't have to check if is null every time.