}
/**
- * @param $module
- * @param $permissions
- * @param $learning
+ * {@inheritdoc}
*/
- public function generate($module, $permissions, $learning)
+ public function generate(array $parameters)
{
- $parameters = [
- 'module_name' => $module,
- 'permissions' => $permissions,
- ];
+ $module = $parameters['module_name'];
+ $learning = $parameters['learning'];
$this->renderFile(
'module/permission.yml.twig',
- $this->extensionManager->getModule($module)->getPath().'/'.$module.'.permissions.yml',
+ $this->extensionManager->getModule($module)->getPath() . '/' . $module . '.permissions.yml',
$parameters,
FILE_APPEND
);
);
if ($learning) {
- echo 'You can use this permission in the routing file like this:'.PHP_EOL;
+ echo 'You can use this permission in the routing file like this:' . PHP_EOL;
echo $content;
}
}