Drupal Coding Standards Issues | phpcs

Created on 23 January 2023, almost 2 years ago
Updated 15 July 2024, 4 months ago

Problem/Motivation

php coding standard shows some minimalistic issue those need to be fixed.

FILE: /Users/sahil.goyal/Documents/MySites/10.1.x/drupal/modules/contrib/node_title/node_title.module
-----------------------------------------------------------------------------------------------------
FOUND 7 ERRORS AFFECTING 5 LINES
-----------------------------------------------------------------------------------------------------
26 | ERROR | [x] Each PHP statement must be on a line by itself
28 | ERROR | [x] Expected 1 space after ".="; 0 found
28 | ERROR | [x] Concat operator must be surrounded by a single space
35 | ERROR | [x] Concat operator must be surrounded by a single space
37 | ERROR | [x] Case breaking statements must be followed by a single blank line
37 | ERROR | [x] Case breaking statement indented incorrectly; expected 6 spaces, found 7
38 | ERROR | [x] Line indented incorrectly; expected 4 spaces, found 7
-----------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 7 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------------------------

Steps to reproduce

phpcs --standard="Drupal,DrupalPractice" --extensions=php,module,inc,install,test,profile,theme,info,txt,md,yml /Users/sahil.goyal/Documents/MySites/10.1.x/drupal/modules/contrib/node_title

Proposed resolution

phpcbf --standard="Drupal,DrupalPractice" --extensions=php,module,inc,install,test,profile,theme,info,txt,md,yml /Users/sahil.goyal/Documents/MySites/10.1.x/drupal/modules/contrib/node_title

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Fixed

Version

2.0

Component

Code

Created by

🇮🇳India sahil.goyal

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

Comments & Activities

Production build 0.71.5 2024