Fix the issues reported by phpcs

Created on 23 March 2023, over 1 year ago
Updated 22 January 2024, 8 months ago

Problem/Motivation

Getting following error/warnings.

FILE: /var/www/html/modules/contrib/paragraphs_tabs_bootstrap/paragraphs_tabs_bootstrap.info.yml
------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
------------------------------------------------------------------------------------------------
7 | ERROR | [x] Expected 1 newline at end of file; 2 found
------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
------------------------------------------------------------------------------------------------

FILE: /var/www/html/modules/contrib/paragraphs_tabs_bootstrap/paragraphs_tabs_bootstrap.module
----------------------------------------------------------------------------------------------
FOUND 2 ERRORS AND 1 WARNING AFFECTING 3 LINES
----------------------------------------------------------------------------------------------
8 | WARNING | [x] Unused use statement
20 | ERROR | [x] Short array syntax must be used to define arrays
33 | ERROR | [x] Short array syntax must be used to define arrays
----------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------------------

FILE: /var/www/html/modules/contrib/paragraphs_tabs_bootstrap/src/Form/AddComponentForm.php
-------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
-------------------------------------------------------------------------------------------
161 | WARNING | Unused variable $is_ajax.
-------------------------------------------------------------------------------------------

Time: 2.29 secs; Memory: 8MB

Steps to reproduce

Run following command

phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml modules/contrib/paragraphs_tabs_bootstrap/

Proposed resolution

Above error/warnings need to be fixed.

๐Ÿ“Œ Task
Status

Fixed

Version

1.0

Component

Code

Created by

๐Ÿ‡ฎ๐Ÿ‡ณIndia samit.310@gmail.com

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