X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=vendor%2Fdrupal%2Fconsole%2Fsrc%2FGenerator%2FPluginRulesActionGenerator.php;fp=vendor%2Fdrupal%2Fconsole%2Fsrc%2FGenerator%2FPluginRulesActionGenerator.php;h=9a4f5592df0d7cb4fe142273493e84ebbfa4849e;hp=a60ee380c17965c8892a952cc47b98b580001e24;hb=9917807b03b64faf00f6a1f29dcb6eafc454efa5;hpb=aea91e65e895364e460983b890e295aa5d5540a5 diff --git a/vendor/drupal/console/src/Generator/PluginRulesActionGenerator.php b/vendor/drupal/console/src/Generator/PluginRulesActionGenerator.php index a60ee380c..9a4f5592d 100644 --- a/vendor/drupal/console/src/Generator/PluginRulesActionGenerator.php +++ b/vendor/drupal/console/src/Generator/PluginRulesActionGenerator.php @@ -29,36 +29,23 @@ class PluginRulesActionGenerator extends Generator } /** - * Generator Plugin RulesAction. - * - * @param $module - * @param $class_name - * @param $label - * @param $plugin_id - * @param $category - * @param $context + * {@inheritdoc} */ - public function generate($module, $class_name, $label, $plugin_id, $category, $context, $type) + public function generate(array $parameters) { - $parameters = [ - 'module' => $module, - 'class_name' => $class_name, - 'label' => $label, - 'plugin_id' => $plugin_id, - 'category' => $category, - 'context' => $context, - 'type' => $type, - ]; + $module = $parameters['module']; + $class_name = $parameters['class_name']; + $plugin_id = $parameters['plugin_id']; $this->renderFile( 'module/src/Plugin/Action/rulesaction.php.twig', - $this->extensionManager->getPluginPath($module, 'Action').'/'.$class_name.'.php', + $this->extensionManager->getPluginPath($module, 'Action') . '/' . $class_name . '.php', $parameters ); $this->renderFile( 'module/system.action.action.yml.twig', - $this->extensionManager->getModule($module)->getPath() .'/config/install/system.action.'.$plugin_id.'.yml', + $this->extensionManager->getModule($module)->getPath() . '/config/install/system.action.' . $plugin_id . '.yml', $parameters ); }