Fix the issues reported by phpcs

Created on 7 July 2023, 12 months ago
Updated 30 January 2024, 5 months ago

Problem/Motivation

FILE: /var/www/html/vb/d_cont/commerce_gravity_payments/README.txt
------------------------------------------------------------------------
FOUND 1 ERROR AND 3 WARNINGS AFFECTING 3 LINES
------------------------------------------------------------------------
3 | WARNING | [ ] Line exceeds 80 characters; contains 159 characters
7 | WARNING | [ ] Line exceeds 80 characters; contains 151 characters
10 | WARNING | [ ] Line exceeds 80 characters; contains 182 characters
10 | ERROR | [x] Expected 1 newline at end of file; 0 found
------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
------------------------------------------------------------------------

FILE: ...tml/vb/d_cont/commerce_gravity_payments/commerce_gravity_payments.info.yml
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
8 | ERROR | [x] Expected 1 newline at end of file; 0 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: .../d_cont/commerce_gravity_payments/src/Exception/PaymentFailedException.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
8 | ERROR | [x] Missing class doc comment
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...ont/commerce_gravity_payments/src/Form/CommerceGravityPaymentsSettings.php
--------------------------------------------------------------------------------
FOUND 4 ERRORS AND 1 WARNING AFFECTING 5 LINES
--------------------------------------------------------------------------------
20 | ERROR | [x] Doc comment star missing
21 | ERROR | [x] Additional blank lines found at end of doc comment
22 | WARNING | [ ] Possible useless method overriding detected
56 | ERROR | [x] Whitespace found at end of line
87 | ERROR | [x] Whitespace found at end of line
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 4 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: /var/www/html/vb/d_cont/commerce_gravity_payments/src/EmergepayClient.php
--------------------------------------------------------------------------------
FOUND 89 ERRORS AND 7 WARNINGS AFFECTING 72 LINES
--------------------------------------------------------------------------------
7 | ERROR | [x] Missing class doc comment
9 | ERROR | [ ] Missing member variable doc comment
10 | ERROR | [ ] Missing member variable doc comment
11 | ERROR | [ ] Class property $auth_token should use lowerCamel naming
| | without underscores
11 | ERROR | [ ] Missing member variable doc comment
12 | ERROR | [ ] Class property $env_url should use lowerCamel naming
| | without underscores
12 | ERROR | [ ] Missing member variable doc comment
14 | ERROR | [ ] Class property $test_env_url should use lowerCamel naming
| | without underscores
14 | ERROR | [ ] Missing member variable doc comment
15 | ERROR | [ ] Class property $prod_env_url should use lowerCamel naming
| | without underscores
15 | ERROR | [ ] Missing member variable doc comment
17 | ERROR | [x] Missing function doc comment
23 | ERROR | [x] Expected 1 space after IF keyword; 0 found
23 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
25 | ERROR | [x] Expected newline after closing brace
25 | ERROR | [x] Expected 1 space after ELSE keyword; 0 found
30 | ERROR | [x] Whitespace found at end of line
31 | ERROR | [x] No space found before comment text; expected "// Helper
| | function used to generate a GUID/UUID" but found "//Helper
| | function used to generate a GUID/UUID"
32 | ERROR | [x] No space found before comment text; expected "// source:
| | http://php.net/manual/en/function.com-create-guid.php#99425"
| | but found "//source:
| | http://php.net/manual/en/function.com-create-guid.php#99425"
33 | ERROR | [ ] Public method name "EmergepayClient::GUID" is not in
| | lowerCamel format
33 | ERROR | [x] You must use "/**" style comments for a function comment
33 | ERROR | [x] Expected 1 space before opening brace; found 0
34 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE"
| | but found "true"
34 | ERROR | [x] Expected 1 space after closing parenthesis; found 5
36 | ERROR | [x] Line indented incorrectly; expected 6 spaces, found 8
45 | ERROR | [x] Parameter comment must be on the next line
46 | ERROR | [x] Parameter comment must be on the next line
47 | ERROR | [x] Separate the @param and @return sections by a blank line.
47 | ERROR | [ ] Description for the @return value must be on the next line
48 | ERROR | [x] Separate the @return and @throws sections by a blank line.
48 | ERROR | [ ] @throws comment must be on the next line
48 | ERROR | [x] Data types in @throws tags need to be fully namespaced
54 | ERROR | [x] Array indentation error, expected 8 spaces but found 10
54 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "FALSE"
| | but found "false"
55 | ERROR | [x] Array indentation error, expected 8 spaces but found 10
55 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE"
| | but found "true"
56 | ERROR | [x] Array indentation error, expected 8 spaces but found 10
56 | ERROR | [ ] The array declaration extends to column 112 (the limit is
| | 80). The array content should be split up over multiple
| | lines
57 | ERROR | [x] Array indentation error, expected 8 spaces but found 10
57 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE"
| | but found "true"
58 | ERROR | [x] Array indentation error, expected 8 spaces but found 10
63 | ERROR | [x] Whitespace found at end of line
68 | ERROR | [x] Expected newline after closing brace
72 | ERROR | [x] Expected newline after closing brace
80 | ERROR | [x] Parameter comment must be on the next line
81 | ERROR | [x] Parameter comment must be on the next line
82 | ERROR | [x] Separate the @param and @return sections by a blank line.
82 | ERROR | [ ] Description for the @return value must be on the next line
83 | ERROR | [x] Separate the @return and @throws sections by a blank line.
83 | ERROR | [ ] @throws comment must be on the next line
83 | ERROR | [x] Data types in @throws tags need to be fully namespaced
88 | ERROR | [x] Expected 1 space after TRY keyword; 0 found
91 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "FALSE"
| | but found "false"
92 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE"
| | but found "true"
96 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: auth_token
99 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: $payload
109 | ERROR | [x] Expected newline after closing brace
113 | ERROR | [x] Expected newline after closing brace
121 | ERROR | [x] Parameter comment must be on the next line
122 | ERROR | [x] Separate the @param and @return sections by a blank line.
122 | ERROR | [ ] Description for the @return value must be on the next line
125 | ERROR | [x] Expected 1 space after "="; 2 found
127 | ERROR | [x] Short array syntax must be used to define arrays
128 | ERROR | [x] Short array syntax must be used to define arrays
132 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: )
135 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
138 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
139 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "NULL"
| | but found "null"
140 | ERROR | [x] Expected 1 blank line after function; 2 found
146 | ERROR | [x] Parameter comment must be on the next line
147 | ERROR | [x] Parameter comment must be on the next line
148 | ERROR | [x] Separate the @param and @return sections by a blank line.
148 | ERROR | [ ] Description for the @return value must be on the next line
153 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
155 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: $transactionData
158 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
162 | ERROR | [x] Expected 1 blank line after function; 2 found
168 | ERROR | [x] Parameter comment must be on the next line
169 | ERROR | [x] Separate the @param and @return sections by a blank line.
169 | ERROR | [ ] Description for the @return value must be on the next line
174 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
176 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: $transactionData
179 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
188 | ERROR | [x] Parameter comment must be on the next line
189 | ERROR | [x] Separate the @param and @return sections by a blank line.
189 | ERROR | [ ] Description for the @return value must be on the next line
194 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
196 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: $transactionData
199 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
208 | ERROR | [x] Parameter comment must be on the next line
209 | ERROR | [x] Separate the @param and @return sections by a blank line.
209 | ERROR | [ ] Description for the @return value must be on the next line
214 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
216 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: $transactionData
219 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
225 | ERROR | [x] Expected 1 newline at end of file; 0 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 75 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...e_gravity_payments/src/PluginForm/EmergepayCredit/PaymentMethodAddForm.php
--------------------------------------------------------------------------------
FOUND 21 ERRORS AND 5 WARNINGS AFFECTING 17 LINES
--------------------------------------------------------------------------------
5 | WARNING | [x] Unused use statement
9 | ERROR | [x] Missing class doc comment
18 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE"
| | but found "true"
22 | ERROR | [x] Expected 1 space after IF keyword; 0 found
22 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
24 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE"
| | but found "true"
26 | ERROR | [x] Functions must not contain multiple empty lines in a row;
| | found 2 empty lines
30 | ERROR | [x] Functions must not contain multiple empty lines in a row;
| | found 2 empty lines
33 | ERROR | [x] Expected 1 space after IF keyword; 0 found
33 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE"
| | but found "true"
33 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
40 | ERROR | [x] Expected 1 space after IF keyword; 0 found
40 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "FALSE"
| | but found "false"
40 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
44 | ERROR | [x] Concat operator must be surrounded by a single space
44 | ERROR | [x] Concat operator must be surrounded by a single space
50 | ERROR | [x] Inline comments must start with a capital letter
50 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
53 | ERROR | [x] Expected 1 space after IF keyword; 0 found
53 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
56 | ERROR | [x] Expected 1 space after IF keyword; 0 found
56 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
103 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: ]
104 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: ]
133 | WARNING | [ ] Unused variable $values.
140 | WARNING | [ ] Unused variable $values.
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 24 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...cont/commerce_gravity_payments/src/PluginForm/PaymentMethodAddFormBase.php
--------------------------------------------------------------------------------
FOUND 13 ERRORS AND 3 WARNINGS AFFECTING 14 LINES
--------------------------------------------------------------------------------
5 | WARNING | [x] Unused use statement
7 | WARNING | [x] Unused use statement
8 | WARNING | [x] Unused use statement
20 | ERROR | [x] Data types in @return tags need to be fully namespaced
24 | ERROR | [x] Expected 1 space after "="; 2 found
25 | ERROR | [x] Whitespace found at end of line
31 | ERROR | [x] Whitespace found at end of line
42 | ERROR | [x] Expected 1 space after "="; 2 found
45 | ERROR | [x] Expected 1 blank line after function; 2 found
48 | ERROR | [x] Missing function doc comment
49 | ERROR | [x] Expected 1 space after IF keyword; 0 found
49 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
53 | ERROR | [x] Language constructs must be followed by a single space;
| | expected 1 space but found "··"
54 | ERROR | [x] Expected 1 blank line after function; 2 found
57 | ERROR | [x] Expected 1 newline at end of file; 0 found
57 | ERROR | [x] The closing brace for the class must have an empty line
| | before it
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 16 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...erce_gravity_payments/src/PluginForm/EmergepayAch/PaymentMethodAddForm.php
--------------------------------------------------------------------------------
FOUND 12 ERRORS AND 5 WARNINGS AFFECTING 11 LINES
--------------------------------------------------------------------------------
5 | WARNING | [x] Unused use statement
9 | ERROR | [x] Missing class doc comment
37 | ERROR | [x] Expected 1 space after IF keyword; 0 found
37 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "FALSE"
| | but found "false"
37 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
41 | ERROR | [x] Concat operator must be surrounded by a single space
41 | ERROR | [x] Concat operator must be surrounded by a single space
47 | ERROR | [x] Inline comments must start with a capital letter
47 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
50 | ERROR | [x] Expected 1 space after IF keyword; 0 found
50 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
53 | ERROR | [x] Expected 1 space after IF keyword; 0 found
53 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
100 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: ]
101 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: ]
112 | WARNING | [ ] Unused variable $values.
119 | WARNING | [ ] Unused variable $values.
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 15 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...ty_payments/src/Plugin/Commerce/PaymentMethodType/CommerceEmergepayAch.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
54 | ERROR | [x] Whitespace found at end of line
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...merce_gravity_payments/src/Plugin/Commerce/PaymentGateway/EmergepayAch.php
--------------------------------------------------------------------------------
FOUND 62 ERRORS AND 12 WARNINGS AFFECTING 47 LINES
--------------------------------------------------------------------------------
40 | ERROR | [ ] Class property $emergepay_config should use lowerCamel
| | naming without underscores
40 | ERROR | [ ] Missing member variable doc comment
41 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "NULL"
| | but found "null"
42 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "NULL"
| | but found "null"
43 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "NULL"
| | but found "null"
44 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "NULL"
| | but found "null"
46 | ERROR | [ ] Class property $emergepay_client should use lowerCamel
| | naming without underscores
46 | ERROR | [ ] Missing member variable doc comment
54 | ERROR | [x] Expected 1 space after "="; 2 found
80 | ERROR | [x] Expected 1 space after "="; 2 found
88 | ERROR | [x] Expected 1 space after IF keyword; 0 found
88 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
93 | ERROR | [x] Space found before comma in argument list
93 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: )
94 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: ]
102 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: )
109 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: )
111 | ERROR | [x] Functions must not contain multiple empty lines in a row;
| | found 3 empty lines
113 | ERROR | [ ] More than 2 empty lines are not allowed
114 | ERROR | [x] Expected 1 space after IF keyword; 0 found
114 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
116 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE"
| | but found "true"
122 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 4
123 | ERROR | [x] Expected 5 space(s) before asterisk; 3 found
124 | ERROR | [x] Expected 5 space(s) before asterisk; 3 found
126 | ERROR | [x] Expected 1 space after "="; 2 found
130 | ERROR | [x] Expected 1 space after IF keyword; 0 found
130 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
131 | ERROR | [x] Space found before comma in argument list
133 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 3
133 | ERROR | [x] Closing brace indented incorrectly; expected 2 spaces,
| | found 3
133 | ERROR | [x] Expected 1 blank line after function; 2 found
161 | ERROR | [x] Whitespace found at end of line
162 | WARNING | [ ] Unused variable $remote_id.
164 | ERROR | [x] Expected 1 space after "="; 2 found
166 | ERROR | [x] Comments may not appear after statements
168 | WARNING | [ ] Line exceeds 80 characters; contains 107 characters
168 | ERROR | [x] Comments may not appear after statements
168 | ERROR | [x] Inline comments must start with a capital letter
168 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
173 | ERROR | [x] Expected 1 space after IF keyword; 0 found
173 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
178 | WARNING | [ ] Unused variable $resultStatus.
180 | ERROR | [x] Expected 1 space after IF keyword; 0 found
180 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
184 | WARNING | [ ] Unused variable $accountExpiryDate.
188 | ERROR | [x] Functions must not contain multiple empty lines in a row;
| | found 2 empty lines
213 | WARNING | [ ] Line exceeds 80 characters; contains 107 characters
213 | ERROR | [x] Comments may not appear after statements
213 | ERROR | [x] Inline comments must start with a capital letter
213 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
216 | ERROR | [x] Expected 1 space after TRY keyword; 0 found
218 | ERROR | [x] Expected 1 space after IF keyword; 0 found
218 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
221 | ERROR | [x] Expected newline after closing brace
221 | ERROR | [x] Expected 1 space after ELSE keyword; 0 found
224 | ERROR | [x] Expected newline after closing brace
224 | ERROR | [x] Expected 1 space after CATCH keyword; 0 found
224 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
239 | WARNING | [ ] Unused variable $payment_method_token.
242 | ERROR | [x] Whitespace found at end of line
248 | WARNING | [ ] Line exceeds 80 characters; contains 107 characters
248 | ERROR | [x] Comments may not appear after statements
248 | ERROR | [x] Inline comments must start with a capital letter
248 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
251 | ERROR | [x] Expected 1 space after TRY keyword; 0 found
254 | ERROR | [x] Expected 1 space after IF keyword; 0 found
254 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
266 | ERROR | [x] Expected newline after closing brace
266 | ERROR | [x] Expected 1 space after ELSE keyword; 0 found
269 | ERROR | [x] Expected newline after closing brace
269 | ERROR | [x] Expected 1 space after CATCH keyword; 0 found
269 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
278 | WARNING | [ ] Unused variable $required_keys.
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 61 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...vity_payments/src/Plugin/Commerce/PaymentGateway/EmergepayAchInterface.php
--------------------------------------------------------------------------------
FOUND 2 ERRORS AFFECTING 2 LINES
--------------------------------------------------------------------------------
10 | ERROR | [x] Missing interface doc comment
12 | ERROR | [x] Expected 1 newline at end of file; 0 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...y_payments/src/Plugin/Commerce/PaymentGateway/EmergepayCreditInterface.php
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
10 | ERROR | [x] Missing interface doc comment
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...ce_gravity_payments/src/Plugin/Commerce/PaymentGateway/EmergepayCredit.php
--------------------------------------------------------------------------------
FOUND 86 ERRORS AND 17 WARNINGS AFFECTING 66 LINES
--------------------------------------------------------------------------------
41 | ERROR | [ ] Class property $emergepay_config should use lowerCamel
| | naming without underscores
41 | ERROR | [ ] Missing member variable doc comment
42 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "NULL"
| | but found "null"
43 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "NULL"
| | but found "null"
44 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "NULL"
| | but found "null"
45 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "NULL"
| | but found "null"
47 | ERROR | [ ] Class property $emergepay_client should use lowerCamel
| | naming without underscores
47 | ERROR | [ ] Missing member variable doc comment
55 | ERROR | [x] Expected 1 space after "="; 2 found
81 | ERROR | [x] Expected 1 space after "="; 2 found
89 | ERROR | [x] Expected 1 space after IF keyword; 0 found
89 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
94 | ERROR | [x] Space found before comma in argument list
94 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: )
95 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: ]
98 | ERROR | [x] Functions must not contain multiple empty lines in a row;
| | found 2 empty lines
104 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: )
111 | WARNING | [x] A comma should follow the last multiline array item.
| | Found: )
113 | ERROR | [x] Functions must not contain multiple empty lines in a row;
| | found 3 empty lines
115 | ERROR | [ ] More than 2 empty lines are not allowed
116 | ERROR | [x] Expected 1 space after IF keyword; 0 found
116 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
118 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "TRUE"
| | but found "true"
124 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 4
125 | ERROR | [x] Expected 5 space(s) before asterisk; 3 found
126 | ERROR | [x] Expected 5 space(s) before asterisk; 3 found
128 | ERROR | [x] Expected 1 space after "="; 2 found
132 | ERROR | [x] Expected 1 space after IF keyword; 0 found
132 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
133 | ERROR | [x] Space found before comma in argument list
135 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 3
135 | ERROR | [x] Closing brace indented incorrectly; expected 2 spaces,
| | found 3
135 | ERROR | [x] Expected 1 blank line after function; 2 found
164 | ERROR | [x] Whitespace found at end of line
165 | WARNING | [ ] Unused variable $remote_id.
166 | ERROR | [x] Whitespace found at end of line
171 | ERROR | [x] Whitespace found at end of line
172 | ERROR | [x] Concat operator must be surrounded by a single space
172 | ERROR | [x] Concat operator must be surrounded by a single space
174 | ERROR | [x] Expected 1 space after "="; 2 found
177 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
178 | ERROR | [x] Concat operator must be surrounded by a single space
178 | ERROR | [x] Concat operator must be surrounded by a single space
179 | ERROR | [x] Expected 1 space after "=>"; 2 found
182 | WARNING | [ ] Line exceeds 80 characters; contains 107 characters
182 | ERROR | [x] Comments may not appear after statements
182 | ERROR | [x] Inline comments must start with a capital letter
182 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
186 | ERROR | [x] Whitespace found at end of line
187 | ERROR | [x] Expected 1 space after IF keyword; 0 found
187 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "FALSE"
| | but found "false"
187 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
192 | WARNING | [ ] Unused variable $resultStatus.
194 | ERROR | [x] Expected 1 space after IF keyword; 0 found
194 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
198 | WARNING | [ ] Unused variable $accountExpiryDate.
203 | WARNING | [ ] Unused variable $accountExpiryDate.
226 | ERROR | [x] Whitespace found at end of line
228 | ERROR | [x] Expected 1 space after IF keyword; 0 found
228 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
232 | ERROR | [x] Expected 1 space after "="; 2 found
235 | ERROR | [x] Comments may not appear after statements
237 | WARNING | [ ] Line exceeds 80 characters; contains 107 characters
237 | ERROR | [x] Comments may not appear after statements
237 | ERROR | [x] Inline comments must start with a capital letter
237 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
241 | ERROR | [x] Whitespace found at end of line
242 | ERROR | [x] Expected 1 space after IF keyword; 0 found
242 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "FALSE"
| | but found "false"
242 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
245 | ERROR | [x] Whitespace found at end of line
247 | WARNING | [ ] Unused variable $resultStatus.
249 | ERROR | [x] Expected 1 space after IF keyword; 0 found
249 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
253 | WARNING | [ ] Unused variable $accountExpiryDate.
254 | WARNING | [ ] Unused variable $maskedAccount.
258 | WARNING | [ ] Unused variable $accountExpiryDate.
278 | WARNING | [ ] Line exceeds 80 characters; contains 107 characters
278 | ERROR | [x] Comments may not appear after statements
278 | ERROR | [x] Inline comments must start with a capital letter
278 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
281 | ERROR | [x] Expected 1 space after TRY keyword; 0 found
283 | ERROR | [x] Expected 1 space after IF keyword; 0 found
283 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
286 | ERROR | [x] Expected newline after closing brace
286 | ERROR | [x] Expected 1 space after ELSE keyword; 0 found
289 | ERROR | [x] Expected newline after closing brace
289 | ERROR | [x] Expected 1 space after CATCH keyword; 0 found
289 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
304 | WARNING | [ ] Unused variable $payment_method_token.
307 | ERROR | [x] Whitespace found at end of line
313 | WARNING | [ ] Line exceeds 80 characters; contains 107 characters
313 | ERROR | [x] Comments may not appear after statements
313 | ERROR | [x] Inline comments must start with a capital letter
313 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
316 | ERROR | [x] Expected 1 space after TRY keyword; 0 found
319 | ERROR | [x] Expected 1 space after IF keyword; 0 found
319 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
331 | ERROR | [x] Expected newline after closing brace
331 | ERROR | [x] Expected 1 space after ELSE keyword; 0 found
334 | ERROR | [x] Expected newline after closing brace
334 | ERROR | [x] Expected 1 space after CATCH keyword; 0 found
334 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 85 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: .../vb/d_cont/commerce_gravity_payments/commerce_gravity_payments.routing.yml
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
7 | ERROR | [x] Expected 1 newline at end of file; 0 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...b/d_cont/commerce_gravity_payments/commerce_gravity_payments.libraries.yml
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
17 | ERROR | [x] Expected 1 newline at end of file; 0 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...mmerce_gravity_payments/config/schema/commerce_gravity_payments.schema.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
--------------------------------------------------------------------------------

Time: 255ms; Memory: 12MB

Steps to reproduce

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

Remaining tasks

Patch review

📌 Task
Status

Needs review

Version

1.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

Merge Requests

Comments & Activities

  • Issue created by @urvashi_vora
  • First commit to issue fork.
  • Status changed to Needs work 12 months ago
  • 🇧🇪Belgium Frederikvho Belgium

    Hi,

    I applied the patch from the issue summary but it still threw quite a few warnings and errors.

    So I created a fork and applied the patch on there, also ran phpcbf to fix some additional errors automatically.

    There still are extra PHPCS errors left. I can't fix those right now as I have no environment ready to test all the variables that have to be changed to lowerCamel. But feel free to continue on the fork, if I haven't already.

  • 🇮🇳India kbk1992 Hyderabad

    bharath-kondeti made their first commit to this issue’s fork.

  • Status changed to Needs review 12 months ago
  • 🇮🇳India urvashi_vora Madhya Pradesh, India

    Marking it to "Needs Review", so that MR1 can be reviewed.

  • Status changed to Needs work 12 months ago
  • 🇵🇭Philippines clarkssquared

    Hi

    I applied the updated MR1 to my local and I noticed that there are still PHPCS errors being flagged. For convenience below are the said PHPCS errors/warnings.

    FILE: /Users/studenttrainees/commerce_gravity_payments/src/Plugin/Commerce/PaymentGateway/EmergepayCredit.php
    -------------------------------------------------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 2 LINES
    -------------------------------------------------------------------------------------------------------------
     46 | ERROR | Class property $emergepay_config should use lowerCamel naming without underscores
     58 | ERROR | Class property $emergepay_client should use lowerCamel naming without underscores
    -------------------------------------------------------------------------------------------------------------
    
    
    FILE: /Users/studenttrainees/commerce_gravity_payments/src/Plugin/Commerce/PaymentGateway/EmergepayAch.php
    ----------------------------------------------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 2 LINES
    ----------------------------------------------------------------------------------------------------------
     45 | ERROR | Class property $emergepay_config should use lowerCamel naming without underscores
     57 | ERROR | Class property $emergepay_client should use lowerCamel naming without underscores
    ----------------------------------------------------------------------------------------------------------
    
    
    FILE: /Users/studenttrainees/commerce_gravity_payments/src/EmergepayClient.php
    -------------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    -------------------------------------------------------------------------------------
     82 | ERROR | Public method name "EmergepayClient::GUID" is not in lowerCamel format
    -------------------------------------------------------------------------------------
    
    Time: 744ms; Memory: 12MB
    
    

    I will also provide the screenshot, kindly check also.

    Thank you

  • First commit to issue fork.
  • 🇮🇳India Preethy_ray

    pray_12 made their first commit to this issue’s fork.

  • First commit to issue fork.
  • Status changed to Needs review 5 months ago
  • 🇮🇳India Preethy_ray

    Hi,
    Reviewed MR!1 [#10 ]. Found no phpcs errors or warnings.

Production build 0.69.0 2024