Coding Standard Issues

Created on 4 March 2024, 9 months ago
Updated 23 March 2024, 8 months ago

Problem/Motivation

Found Drupal coding standard issues on the module using following command

vendor/bin/phpcs --standard=Drupal,DrupalPractice --extensions='php,module,inc,yml,install,test,profile,theme,info,txt,md,twig' ./

Issues are:

FILE: /var/www/html/d_10/web/modules/contrib/active_menu_item_by_path/src/Form/ActiveMenuItemByPathSettingsForm.php
--------------------------------------------------------------------------------------------------------------------------
FOUND 12 ERRORS AND 1 WARNING AFFECTING 13 LINES
--------------------------------------------------------------------------------------------------------------------------
 14 | ERROR   | [x] Missing class doc comment
 20 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing
    |         |     parentheses
 28 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing
    |         |     parentheses
 38 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing
    |         |     parentheses
 41 | WARNING | [ ] Menu::loadMultiple calls should be avoided in classes, use dependency injection instead
 43 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing
    |         |     parentheses
 46 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing
    |         |     parentheses
 49 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing
    |         |     parentheses
 57 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing
    |         |     parentheses
 65 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing
    |         |     parentheses
 68 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing
    |         |     parentheses
 71 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing
    |         |     parentheses
 76 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing
    |         |     parentheses

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

🇮🇳India swapnil22

Live updates comments and jobs are added and updated live.
  • Coding standards

    It involves compliance with, or the content of coding standards. Requires broad community agreement.

Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024