diff options
| author | Greg Roach <fisharebest@webtrees.net> | 2019-10-25 21:31:59 +0100 |
|---|---|---|
| committer | Greg Roach <fisharebest@webtrees.net> | 2019-10-25 21:31:59 +0100 |
| commit | 75964c75fd01f8e12e2a313cc89fc2222413a03f (patch) | |
| tree | 11e854fbe3a11b1c923556f593e27250b3ceec4c /app/Services/UserService.php | |
| parent | 062e72369ad5a64ec7e9a8866dd25ed2c46b14a7 (diff) | |
| download | webtrees-75964c75fd01f8e12e2a313cc89fc2222413a03f.tar.gz webtrees-75964c75fd01f8e12e2a313cc89fc2222413a03f.tar.bz2 webtrees-75964c75fd01f8e12e2a313cc89fc2222413a03f.zip | |
No need to throw exceptions in assert()
Diffstat (limited to 'app/Services/UserService.php')
| -rw-r--r-- | app/Services/UserService.php | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/app/Services/UserService.php b/app/Services/UserService.php index 1f74865ed3..8caa990382 100644 --- a/app/Services/UserService.php +++ b/app/Services/UserService.php @@ -27,7 +27,6 @@ use Fisharebest\Webtrees\User; use Illuminate\Database\Capsule\Manager as DB; use Illuminate\Database\Query\JoinClause; use Illuminate\Support\Collection; -use InvalidArgumentException; use Psr\Http\Message\ServerRequestInterface; use function app; @@ -354,7 +353,7 @@ class UserService public function contactLink(User $contact_user, ServerRequestInterface $request): string { $tree = $request->getAttribute('tree'); - assert($tree instanceof Tree, new InvalidArgumentException()); + assert($tree instanceof Tree); $user = $request->getAttribute('user'); |
