mirror of
https://github.com/kevinveenbirkenbach/infinito.git
synced 2025-09-13 13:57:10 +02:00
implemented checking of source source attributs
This commit is contained in:
@@ -4,9 +4,9 @@ namespace App\Domain\SecureLoadManagement;
|
||||
|
||||
use App\Entity\Source\SourceInterface;
|
||||
use App\Entity\Meta\RightInterface;
|
||||
use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException;
|
||||
use Doctrine\Common\Persistence\ObjectRepository;
|
||||
use App\Domain\SecureManagement\SecureSourceChecker;
|
||||
use App\Exception\SourceAccessDenied;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
@@ -71,6 +71,6 @@ final class SecureSourceLoader implements SecureSourceLoaderInterface
|
||||
if ($secureSourceChecker->hasPermission($requestedRight)) {
|
||||
return $source;
|
||||
}
|
||||
throw new AccessDeniedHttpException();
|
||||
throw new SourceAccessDenied();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user