Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
PHPCS reported the following issues.
FILE: simple_affiliate/README.txt
---------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 5 WARNINGS AFFECTING 5 LINES
---------------------------------------------------------------------------------------------
3 | WARNING | Line exceeds 80 characters; contains 102 characters
7 | WARNING | Line exceeds 80 characters; contains 111 characters
8 | WARNING | Line exceeds 80 characters; contains 115 characters
11 | WARNING | Line exceeds 80 characters; contains 124 characters
12 | WARNING | Line exceeds 80 characters; contains 125 characters
---------------------------------------------------------------------------------------------
FILE: simple_affiliate/simple_affiliate.module
----------------------------------------------------------------------------------------------------------
FOUND 6 ERRORS AND 2 WARNINGS AFFECTING 5 LINES
----------------------------------------------------------------------------------------------------------
1 | ERROR | [x] Missing file doc comment
9 | WARNING | [ ] Hook implementations should not duplicate @param documentation
9 | ERROR | [ ] Missing parameter comment
11 | WARNING | [ ] Hook implementations should not duplicate @return documentation
11 | ERROR | [ ] Description for the @return value is missing
18 | ERROR | [x] Short array syntax must be used to define arrays
22 | ERROR | [x] Line indented incorrectly; expected 6 spaces, found 4
22 | ERROR | [x] Object operator not indented correctly; expected 6 spaces but found 4
----------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 4 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------------------------------
FILE: simple_affiliate/src/Plugin/Block/AffiliateLinkBlock.php
--------------------------------------------------------------------------------------------------------------------------
FOUND 3 ERRORS AND 1 WARNING AFFECTING 4 LINES
--------------------------------------------------------------------------------------------------------------------------
1 | ERROR | [x] The PHP open tag must be followed by exactly one blank line
4 | ERROR | [x] There must be one blank line after the namespace declaration
8 | WARNING | [x] Unused use statement
21 | ERROR | [ ] Missing short description in doc comment
--------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------------------------------------------------
Comment | File | Size | Author |
---|---|---|---|
#3 | 3127050-3.patch | 3.05 KB | Gaurav_drupal |
Comments
Comment #2
Gaurav_drupalProvided patch, please review.
Comment #3
Gaurav_drupalProvided correct patch.
Comment #5
binnythomas CreditAttribution: binnythomas at Axelerant for Drupal India Association commentedApplied the patch. Thanks for the patch.