Fix the issues reported by PHPCS

Created on 20 April 2023, almost 2 years ago

Problem/Motivation

FILE: /var/www/html/contribution/drupal10/web/modules/contrib/like/js/like.js
-------------------------------------------------------------------------------
FOUND 10 ERRORS AFFECTING 7 LINES
-------------------------------------------------------------------------------
8 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE" but
| | found "true"
19 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE" but
| | found "true"
32 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE" but
| | found "true"
37 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "NULL" but
| | found "null"
49 | ERROR | [x] Expected 1 space before "/"; 0 found
49 | ERROR | [x] Expected 1 space after "/"; 0 found
49 | ERROR | [x] Expected 1 space before "/"; 0 found
49 | ERROR | [x] Expected 1 space after "/"; 0 found
57 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "FALSE" but
| | found "false"
59 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE" but
| | found "true"
-------------------------------------------------------------------------------
PHPCBF CAN FIX THE 10 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-------------------------------------------------------------------------------

FILE: ...tion/drupal10/web/modules/contrib/like/tests/like_test/like_test.info.yml
-------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
-------------------------------------------------------------------------------
1 | WARNING | Remove "version" from the info file, it will be added by
| | drupal.org packaging automatically
-------------------------------------------------------------------------------

FILE: .../web/modules/contrib/like/tests/src/FunctionalJavascript/LikeBaseTest.php
-------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
-------------------------------------------------------------------------------
63 | ERROR | The array declaration extends to column 87 (the limit is 80).
| | The array content should be split up over multiple lines
-------------------------------------------------------------------------------

Time: 1.22 secs; Memory: 12MB

Steps to reproduce

Execute: phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,js,info,txt,md,yml,twig like/

Proposed resolution

Fix the issues reported for Drupal and DrupalPractice standards.

Remaining tasks

Patch Review

📌 Task
Status

Closed: won't fix

Version

2.0

Component

Code

Created by

🇮🇳India urvashi_vora Madhya Pradesh, India

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