Fix the warnings/errors reported by PHP_CodeSniffer

Created on 23 June 2023, over 1 year ago
Updated 27 July 2023, over 1 year ago

-----------------------------------------------------------------------------------------------------------
FOUND 84 ERRORS AND 1 WARNING AFFECTING 69 LINES
-----------------------------------------------------------------------------------------------------------
1 | ERROR | [x] Missing file doc comment
3 | ERROR | [x] Missing function doc comment
7 | ERROR | [x] Short array syntax must be used to define arrays
14 | ERROR | [x] Short array syntax must be used to define arrays
19 | ERROR | [x] Short array syntax must be used to define arrays
27 | ERROR | [x] Short array syntax must be used to define arrays
36 | ERROR | [x] Short array syntax must be used to define arrays
43 | ERROR | [x] Short array syntax must be used to define arrays
52 | ERROR | [x] Short array syntax must be used to define arrays
56 | ERROR | [x] Expected one space after the comma, 0 found
61 | ERROR | [x] Short array syntax must be used to define arrays
69 | ERROR | [x] Short array syntax must be used to define arrays
74 | ERROR | [x] Short array syntax must be used to define arrays
75 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
76 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
80 | ERROR | [x] Short array syntax must be used to define arrays
82 | WARNING | [ ] Avoid backslash escaping in translatable strings when possible, use "" quotes instead
88 | ERROR | [x] Short array syntax must be used to define arrays
93 | ERROR | [x] Short array syntax must be used to define arrays
94 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
95 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
96 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
97 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
98 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
99 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
100 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
101 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
105 | ERROR | [x] Short array syntax must be used to define arrays
114 | ERROR | [x] Short array syntax must be used to define arrays
122 | ERROR | [x] Short array syntax must be used to define arrays
123 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
124 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
125 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
125 | ERROR | [x] Concat operator must be surrounded by a single space
125 | ERROR | [x] Concat operator must be surrounded by a single space
128 | ERROR | [x] Short array syntax must be used to define arrays
136 | ERROR | [x] Short array syntax must be used to define arrays
137 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
138 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
139 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
139 | ERROR | [x] Concat operator must be surrounded by a single space
139 | ERROR | [x] Concat operator must be surrounded by a single space
142 | ERROR | [x] Short array syntax must be used to define arrays
150 | ERROR | [x] Short array syntax must be used to define arrays
151 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
152 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
153 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
153 | ERROR | [x] Concat operator must be surrounded by a single space
153 | ERROR | [x] Concat operator must be surrounded by a single space
156 | ERROR | [x] Short array syntax must be used to define arrays
164 | ERROR | [x] Short array syntax must be used to define arrays
165 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
166 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
167 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
167 | ERROR | [x] Concat operator must be surrounded by a single space
167 | ERROR | [x] Concat operator must be surrounded by a single space
170 | ERROR | [x] Short array syntax must be used to define arrays
178 | ERROR | [x] Short array syntax must be used to define arrays
179 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
180 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
181 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
181 | ERROR | [x] Concat operator must be surrounded by a single space
181 | ERROR | [x] Concat operator must be surrounded by a single space
184 | ERROR | [x] Short array syntax must be used to define arrays
192 | ERROR | [x] Short array syntax must be used to define arrays
193 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
194 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
195 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
195 | ERROR | [x] Concat operator must be surrounded by a single space
195 | ERROR | [x] Concat operator must be surrounded by a single space
198 | ERROR | [x] Short array syntax must be used to define arrays
206 | ERROR | [x] Short array syntax must be used to define arrays
207 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
208 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
209 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
209 | ERROR | [x] Concat operator must be surrounded by a single space
209 | ERROR | [x] Concat operator must be surrounded by a single space
212 | ERROR | [x] Short array syntax must be used to define arrays
220 | ERROR | [x] Short array syntax must be used to define arrays
228 | ERROR | [x] Short array syntax must be used to define arrays
229 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
230 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
231 | ERROR | [x] Array indentation error, expected 4 spaces but found 3
231 | ERROR | [x] Concat operator must be surrounded by a single space
231 | ERROR | [x] Concat operator must be surrounded by a single space
-----------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 84 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------------------------------

📌 Task
Status

Needs review

Version

1.0

Component

Code

Created by

🇮🇳India sonam_sharma

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.

  • Needs issue summary update

    Issue summaries save everyone time if they are kept up-to-date. See Update issue summary task instructions.

Sign in to follow issues

Comments & Activities

  • Issue created by @sonam_sharma
  • Issue was unassigned.
  • Status changed to Needs work over 1 year ago
  • 🇮🇹Italy apaderno Brescia, 🇮🇹

    The issue summary should always describe what the issue is trying to fix and, in the case of coding standards issues, show which command and arguments have been used and which report that command shown. In this way, project maintainers can verify the patch/MR fixes all the warnings/errors.

  • Status changed to Needs review over 1 year ago
  • 🇮🇳India chaitanyadessai Goa

    Please review patch. fixed all errors reported by phpcs executed command --standard=Drupal,DrupalPractice --extensions=php,module,install,inc,theme.

Production build 0.71.5 2024