Drupal Coding standard issues.
FILE: /var/www/html/Contribution/searchjson/search_json.module
----------------------------------------------------------------------
FOUND 12 ERRORS AFFECTING 12 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but
| | found "\r\n"
12 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found
| | 0
13 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found
| | 0
14 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found
| | 0
15 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found
| | 0
16 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found
| | 0
23 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found
| | 0
24 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found
| | 0
25 | ERROR | [x] Short array syntax must be used to define arrays
26 | ERROR | [x] Short array syntax must be used to define arrays
27 | ERROR | [x] Short array syntax must be used to define arrays
28 | ERROR | [x] Short array syntax must be used to define arrays
----------------------------------------------------------------------
PHPCBF CAN FIX THE 12 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: /var/www/html/Contribution/searchjson/search_json.routing.yml
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
16 | ERROR | [x] Expected 1 newline at end of file; 0 found
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...www/html/Contribution/searchjson/src/Form/SearchjsonSettings.php
----------------------------------------------------------------------
FOUND 4 ERRORS AFFECTING 4 LINES
----------------------------------------------------------------------
25 | ERROR | [x] Short array syntax must be used to define arrays
28 | ERROR | [x] Short array syntax must be used to define arrays
33 | ERROR | [x] Short array syntax must be used to define arrays
39 | ERROR | [x] Short array syntax must be used to define arrays
----------------------------------------------------------------------
PHPCBF CAN FIX THE 4 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...html/Contribution/searchjson/src/Controller/SearchController.php
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
16 | ERROR | [x] Short array syntax must be used to define arrays
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
Comments
Comment #2
sivaprasadc commentedHi,
I have created the Patch for the same. PFA.
Comment #3
akash.addweb commented@Sivaprasad C, Thanks for providing a patch, Your patch clears all the errors of the short array index. I verify with pareview & the errors you mentioned above. It is working fine for me.
Comment #4
akash.addweb commentedComment #6
pvsureshmca commentedThanks for fixing this issues Guys.
Comment #7
pvsureshmca commentedComment #8
pvsureshmca commented