Security update for Core, with self-updated composer
[yaffs-website] / vendor / drupal / console / src / Generator / PluginRulesActionGenerator.php
index a60ee380c17965c8892a952cc47b98b580001e24..9a4f5592df0d7cb4fe142273493e84ebbfa4849e 100644 (file)
@@ -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
         );
     }