public getContributedSongs ( ) : Illuminate\Database\Eloquent\Collection | ||
return | Illuminate\Database\Eloquent\Collection |
public function getContributedSongs()
{
return Song::whereContributingArtistId($this->id)->get();
}
protected function fromArtist(Artist $artist) { // Don't forget the contributed songs. $songs = $artist->songs->merge($artist->getContributedSongs()); return $this->fromMultipleSongs($songs); }