Fix for tests

This commit is contained in:
Hillel Coren 2017-01-01 14:54:17 +02:00
parent 7515ccd321
commit 8e348d83aa

View File

@ -395,6 +395,11 @@ class User extends Authenticatable
return (($entity && $this->can('edit', $entity))
|| (!$entity && $this->can('create', $entityType)));
}
public function primaryAccount()
{
return $this->account->company->accounts->sortBy('id')->first();
}
}
User::updating(function ($user) {