Problem/Motivation
Fix the following coding standard issues https://git.drupalcode.org/project/bootstrap_cloud/-/jobs/79688
$ vendor/bin/phpcs -s $_WEB_ROOT/modules/custom --report-junit=junit.xml --report-full --report-summary --report-source
FILE: ...cloud/web/modules/custom/bootstrap_cloud/src/SubthemeManager.php
----------------------------------------------------------------------
FOUND 2 ERRORS AFFECTING 2 LINES
----------------------------------------------------------------------
8 | ERROR | [x] Use statements should be sorted alphabetically. The
| | first wrong one is
| | Drupal\Core\Extension\ThemeHandlerInterface.
| | (SlevomatCodingStandard.Namespaces.AlphabeticallySortedUses.IncorrectlyOrderedUses)
41 | ERROR | [ ] Parameter $theme_handler is not described in
| | comment
| | (Drupal.Commenting.FunctionComment.ParamMissingDefinition)
----------------------------------------------------------------------
Time: 251ms; Memory: 8MB
PHP CODE SNIFFER REPORT SUMMARY
----------------------------------------------------------------------
FILE ERRORS WARNINGS
----------------------------------------------------------------------
...es/custom/bootstrap_cloud/src/SubthemeManager.php 2 0
----------------------------------------------------------------------
A TOTAL OF 2 ERRORS AND 0 WARNINGS WERE FOUND IN 6 FILES
----------------------------------------------------------------------
PHP CODE SNIFFER VIOLATION SOURCE SUMMARY
----------------------------------------------------------------------
SOURCE COUNT
----------------------------------------------------------------------
[ ] Drupal.Commenting.FunctionComment.ParamMissingDefinition 1
[x] SlevomatCodingStandard.Namespaces.AlphabeticallySortedUses. 1
----------------------------------------------------------------------
A TOTAL OF 2 SNIFF VIOLATIONS WERE FOUND IN 2 SOURCES
----------------------------------------------------------------------
Steps to reproduce
Run following command
phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml bootstrap_cloud/
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | bootstrap_cloud-3386275.patch | 1.11 KB | sarwan_verma |
Issue fork bootstrap_cloud-3386275
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 #2
yasComment #3
yasComment #4
sarwan_verma commentedHi @yas,
I have fixed this issue and also attached the patch file.
Please review and verify.
Comment #5
akshay.singh commentedComment #6
yas@sarwan
Thank you for the patch. Can you please create the MR?
@akshay.singh
Sorry, we will keep the commit message (from the title) to fix the coding standards like' Comply with Drupal coding standards' in this project.
Thanks
Comment #8
yas@sarwan
Thank you for creating the MR and sorry for my late response. I have not noticed the MR since this issue status has been Needs work. Please change the status Needs review in the future when you update the issue so that you can let us know the update.
I'll merge the patch to
5.xand6.x, and close this issue as Fixed.Comment #11
yas