Skip to content

Commit

Permalink
Replace $container has check with hasParameter (#7769)
Browse files Browse the repository at this point in the history
  • Loading branch information
Buratinas authored Mar 19, 2022
1 parent 8b8e8c9 commit b4772fb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/DependencyInjection/SonataAdminExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -144,9 +144,9 @@ public function load(array $configs, ContainerBuilder $container): void

break;
case 'sonata.admin.security.handler.acl':
if (!$container->has('security.acl.provider')) {
if (!isset($bundles['AclBundle'])) {
throw new \RuntimeException(
'The "security.acl.provider" service is needed to use ACL as security handler.'
'The "symfony/acl-bundle" is needed to use ACL as security handler.'
.' You MUST install and enable the "symfony/acl-bundle" bundle.'
);
}
Expand Down

0 comments on commit b4772fb

Please sign in to comment.