diff --git a/src/Commands/SecurityReviewCommands.php b/src/Commands/SecurityReviewCommands.php index e8d3895..c462bff 100644 --- a/src/Commands/SecurityReviewCommands.php +++ b/src/Commands/SecurityReviewCommands.php @@ -45,7 +45,7 @@ class SecurityReviewCommands extends DrushCommands { /** * Run the Security Review checklist. * - * @command security_review:security-review + * @command security:review * @option store Write results to the database * @option log Log results of each check to watchdog, defaults to off * @option lastrun Do not run the checklist, just print last results @@ -243,7 +243,7 @@ class SecurityReviewCommands extends DrushCommands { * @return \Drupal\security_review\Check|null * The found Check. */ - public function getCheck($check_name) { + private function getCheck($check_name) { // Default namespace is Security Review. $namespace = 'security_review'; $title = $check_name; @@ -257,32 +257,4 @@ class SecurityReviewCommands extends DrushCommands { return $this->checklistService->getCheck($namespace, $title); } - /** - * An example of the table output format. - * - * @command security_review-token - * @aliases token - * @field-labels - * group: Group - * token: Token - * name: Name - * @default-fields group,token,name - * - * @return \Consolidation\OutputFormatters\StructuredData\RowsOfFields - * Row of results. - */ - public function token($options = ['format' => 'table']) { - $all = \Drupal::token()->getInfo(); - foreach ($all['tokens'] as $group => $tokens) { - foreach ($tokens as $key => $token) { - $rows[] = [ - 'group' => $group, - 'token' => $key, - 'name' => $token['name'], - ]; - } - } - return new RowsOfFields($rows); - } - }