[SecurityBundle] disable the init:acl command if ACL is not used

This commit is contained in:
Tobias Schultze 2015-11-26 20:19:29 +01:00
parent fd140fc045
commit 55f84a3369
1 changed files with 12 additions and 0 deletions

View File

@ -23,6 +23,18 @@ use Doctrine\DBAL\Schema\SchemaException;
*/
class InitAclCommand extends ContainerAwareCommand
{
/**
* {@inheritdoc}
*/
public function isEnabled()
{
if (!$this->getContainer()->has('security.acl.dbal.connection')) {
return false;
}
return parent::isEnabled();
}
/**
* {@inheritdoc}
*/