Skip to content

Commit

Permalink
Removed default 'N/A' from Couples
Browse files Browse the repository at this point in the history
  • Loading branch information
kreaweb.be committed Jul 31, 2024
1 parent 1fa67e1 commit b523e1d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/Models/Couple.php
Original file line number Diff line number Diff line change
Expand Up @@ -114,13 +114,13 @@ protected function getDateStartFormattedAttribute(): ?string
/* returns PARTNER 1 (1 Person) based on person1_id in Couple model */
public function person_1(): BelongsTo
{
return $this->belongsTo(Person::class, 'person1_id')->withDefault(['name' => 'N/A']);
return $this->belongsTo(Person::class, 'person1_id');
}

/* returns PARTNER 2 (1 Person) based on person2_id in Couple model */
public function person_2(): BelongsTo
{
return $this->belongsTo(Person::class, 'person2_id')->withDefault(['name' => 'N/A']);
return $this->belongsTo(Person::class, 'person2_id');
}

/* returns ALL CHILDREN (n Person) based on parents_id in Person model */
Expand Down

0 comments on commit b523e1d

Please sign in to comment.