Addresses now a collection
This commit is contained in:
@@ -206,10 +206,9 @@ class Account extends Model implements IDs
|
||||
/**
|
||||
* Get the address for the account
|
||||
*
|
||||
* @return array
|
||||
* @todo Change this to return a collection
|
||||
* @return Collection
|
||||
*/
|
||||
public function getAddressAttribute(): array
|
||||
public function getAddressAttribute(): Collection
|
||||
{
|
||||
return collect([
|
||||
'address1' => $this->address1,
|
||||
@@ -219,9 +218,7 @@ class Account extends Model implements IDs
|
||||
$this->state,
|
||||
$this->zip)
|
||||
])
|
||||
->filter()
|
||||
->values()
|
||||
->toArray();
|
||||
->filter();
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user