Drupal Coding Standard

Created on 3 December 2022, almost 2 years ago
Updated 25 June 2023, over 1 year ago

Problem/Motivation

FILE: /var/www/html/drupal_9.4/drupal/web/modules/contrib/block_token/src/BlockTokenPermissions.php
----------------------------------------------------------------------------------------------------------------------------------------------
FOUND 9 ERRORS AND 3 WARNINGS AFFECTING 8 LINES
----------------------------------------------------------------------------------------------------------------------------------------------
  6 | WARNING | [x] Unused use statement
  8 | WARNING | [x] Unused use statement
 11 | ERROR   | [x] Missing class doc comment
 13 | WARNING | [ ] There must be no blank line following an inline comment
 13 | ERROR   | [x] Line indented incorrectly; expected 2 spaces, found 0
 13 | ERROR   | [x] 2 spaces found before inline comment; expected "// use StringTranslationTrait;" but found "//  use
    |         |     StringTranslationTrait;"
 13 | ERROR   | [x] Inline comments must start with a capital letter
 13 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing parentheses
 39 | ERROR   | [x] Missing function doc comment
 42 | ERROR   | [x] Short array syntax must be used to define arrays
 48 | ERROR   | [x] Expected 1 blank line after function; 0 found
 49 | ERROR   | [x] The closing brace for the class must have an empty line before it
----------------------------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 11 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------------------------------------------------------------------


FILE: /var/www/html/drupal_9.4/drupal/web/modules/contrib/block_token/src/Routing/RouteSubscriber.php
------------------------------------------------------------------------------------------------------------------------------
FOUND 6 ERRORS AND 2 WARNINGS AFFECTING 7 LINES
------------------------------------------------------------------------------------------------------------------------------
  8 | ERROR   | [x] Missing class doc comment
 15 | WARNING | [x] There must be no blank line following an inline comment
 15 | WARNING | [ ] There must be no blank line following an inline comment
 17 | ERROR   | [x] Inline comments must end in full-stops, exclamation marks, question marks, colons, or closing parentheses
 19 | ERROR   | [x] Short array syntax must be used to define arrays
 25 | ERROR   | [x] Short array syntax must be used to define arrays
 29 | ERROR   | [x] Expected 1 blank line after function; 0 found
 30 | ERROR   | [x] The closing brace for the class must have an empty line before it
------------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 7 MARKED SNIFF VIOLATIONS AUTOMATICALLY
------------------------------------------------------------------------------------------------------------------------------

Time: 80ms; Memory: 10MB
📌 Task
Status

Fixed

Version

1.0

Component

Code

Created by

🇮🇳India Rohit Rana

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024