vendor/ibexa/core/src/lib/MVC/Symfony/Security/Exception/UnauthorizedSiteAccessException.php line 17

Open in your IDE?
  1. <?php
  2. /**
  3.  * @copyright Copyright (C) Ibexa AS. All rights reserved.
  4.  * @license For full copyright and license information view LICENSE file distributed with this source code.
  5.  */
  6. namespace Ibexa\Core\MVC\Symfony\Security\Exception;
  7. use Exception;
  8. use Ibexa\Core\MVC\Symfony\SiteAccess;
  9. use Symfony\Component\Security\Core\Exception\AccessDeniedException;
  10. /**
  11.  * This exception is thrown when a user tries to authenticate against a SiteAccess
  12.  * for which he doesn't have user/login permission for.
  13.  */
  14. class UnauthorizedSiteAccessException extends AccessDeniedException
  15. {
  16.     public function __construct(SiteAccess $siteAccess$usernameException $previous null)
  17.     {
  18.         parent::__construct("User '$username' doesn't have user/login permission to SiteAccess '$siteAccess->name'"$previous);
  19.     }
  20. }
  21. class_alias(UnauthorizedSiteAccessException::class, 'eZ\Publish\Core\MVC\Symfony\Security\Exception\UnauthorizedSiteAccessException');