You should use the `check()` method here like:
```php
if (!$application->getUser()->check('admin'))
```
Otherwise an exception would be thrown and the following code would not be executed.