FILE: /background_image/src/Form/BackgroundImageHandlerForm.php
--------------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
--------------------------------------------------------------------------------------------------------------------
36 | WARNING | Possible useless method overriding detected
--------------------------------------------------------------------------------------------------------------------
FILE: /background_image/src/BackgroundImageFormTrait.php
-------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
-------------------------------------------------------------------------------------------------------------
300 | WARNING | Only string literals should be passed to t() where possible
-------------------------------------------------------------------------------------------------------------
Issue fork background_image-3400478
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #5
chetan 11 commentedComment #6
clarkssquared commentedHi chetan
I applied your MR !6 and I confirmed that it fixes some of the PHPCS issues but there are lots of PHPCS issues that is found in the module, hence I will move this to needs work.
Comment #7
zkhan.aamir commentedComment #8
zkhan.aamir commentedComment #9
zkhan.aamir commentedFixed some of the issues
Still there are remaining issues related to doc comment and DI
Comment #11
pray_12 commentedHi,
I applied MR !6 (#10) and I found that it fixes few of the PHPCS issues and still some errors are found. Hence I will move this to needs work.
FILE: /background_image/src/Controller/BackgroundImageCssController.php
------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AND 2 WARNINGS AFFECTING 1 LINE
------------------------------------------------------------------------------------------------------------------------
342 | WARNING | The deprecation-version 'drupal:8.0-1.4' does not match the lower-case machine-name standard:
| | drupal:n.n.n or project:n.x-n.n or project:n.x-n.n-label[n] or project:n.n.n or project:n.n.n-label[n]
342 | WARNING | The removal-version 'drupal:8.0-2.0' does not match the lower-case machine-name standard: drupal:n.n.n
| | or project:n.x-n.n or project:n.x-n.n-label[n] or project:n.n.n or project:n.n.n-label[n]
342 | ERROR | Each @deprecated tag must have a @see tag immediately following it
------------------------------------------------------------------------------------------------------------------------
FILE: /background_image/src/Form/BackgroundImageSettingsForm.php
---------------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
---------------------------------------------------------------------------------------------------------------------
51 | WARNING | \Drupal calls should be avoided in classes, use dependency injection instead
---------------------------------------------------------------------------------------------------------------------
FILE: /background_image/src/Form/BackgroundImageHandlerForm.php
--------------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
--------------------------------------------------------------------------------------------------------------------
36 | WARNING | Possible useless method overriding detected
--------------------------------------------------------------------------------------------------------------------
FILE: /background_image/src/Form/BackgroundImageForm.php
-------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 5 WARNINGS AFFECTING 5 LINES
-------------------------------------------------------------------------------------------------------------
611 | WARNING | Do not pass empty strings to t()
992 | WARNING | Unused variable $target.
995 | WARNING | Unused variable $target.
998 | WARNING | Unused variable $target.
1001 | WARNING | Unused variable $target.
-------------------------------------------------------------------------------------------------------------
FILE: background_image/src/BackgroundImageFormTrait.php
-------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
-------------------------------------------------------------------------------------------------------------
300 | WARNING | Only string literals should be passed to t() where possible
-------------------------------------------------------------------------------------------------------------
FILE: background_image/src/BackgroundImageManager.php
-----------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AND 5 WARNINGS AFFECTING 6 LINES
-----------------------------------------------------------------------------------------------------------
339 | ERROR | Parameter tags must be defined first in a doc comment
355 | WARNING | \Drupal calls should be avoided in classes, use dependency injection instead
408 | WARNING | \Drupal calls should be avoided in classes, use dependency injection instead
483 | WARNING | Unused variable $bundle_entity_type.
676 | WARNING | Line exceeds 80 characters; contains 82 characters
776 | WARNING | \Drupal calls should be avoided in classes, use dependency injection instead
-----------------------------------------------------------------------------------------------------------
FILE: background_image/src/BackgroundImageViewBuilder.php
---------------------------------------------------------------------------------------------------------------
FOUND 4 ERRORS AFFECTING 4 LINES
---------------------------------------------------------------------------------------------------------------
75 | ERROR | [x] Expected 1 blank line before function; 2 found
80 | ERROR | [x] Expected 1 space between type hint and argument "$entity_display_repository"; 0 found
305 | ERROR | [ ] Description for the @return value is missing
323 | ERROR | [x] list(...) is forbidden, use [...] instead.
---------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
---------------------------------------------------------------------------------------------------------------
FILE: background_image/src/BackgroundImageSettings.php
------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
------------------------------------------------------------------------------------------------------------
200 | WARNING | Unused variable $diff_value.
------------------------------------------------------------------------------------------------------------
Comment #13
pray_12 commentedComment #14
pray_12 commentedStill few errors and warnings are found
Comment #15
zkhan.aamir commentedIssue summary updated.
Comment #16
nigelcunningham commentedApplying the merge request as it stands; it deals with nearly all the complaints.