Problem/Motivation

FILE: ...ibution/drupal/web/modules/contrib/reserved_paths/src/Form/AdminForm.php
--------------------------------------------------------------------------------
FOUND 16 ERRORS AND 4 WARNINGS AFFECTING 19 LINES
--------------------------------------------------------------------------------
9 | ERROR | [x] Expected 1 space(s) before asterisk; 0 found
10 | ERROR | [x] Expected 1 space(s) before asterisk; 0 found
14 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
15 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
21 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
22 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
30 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
31 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
32 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
33 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
34 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
40 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
41 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
43 | WARNING | [ ] Unused variable $fields.
60 | ERROR | [x] Missing function doc comment
66 | WARNING | [ ] t() calls should be avoided in classes, use
| | \Drupal\Core\StringTranslation\StringTranslationTrait and
| | $this->t() instead
66 | WARNING | [ ] Only string literals should be passed to t() where possible
72 | WARNING | [ ] t() calls should be avoided in classes, use
| | \Drupal\Core\StringTranslation\StringTranslationTrait and
| | $this->t() instead
88 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
89 | ERROR | [x] Expected 3 space(s) before asterisk; 2 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 16 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...ribution/drupal/web/modules/contrib/reserved_paths/reserved_paths.module
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
10 | ERROR | [x] Missing function doc comment
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...w/html/contribution/drupal/web/modules/contrib/reserved_paths/README.txt
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
40 | ERROR | [x] Expected 1 newline at end of file; 0 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

Time: 300ms; Memory: 10MB

Steps to reproduce

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

Proposed resolution

Fix all the errors and warnings

Remaining tasks

"Unused variable $fields." - Left this error because may be the maintainer might need it in future code.

Patch review.

Command icon 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

urvashi_vora created an issue. See original summary.

kaustab_roy’s picture

StatusFileSize
new1.49 KB
new1.49 KB

patch#0 applied cleanly & it fixes most of the issues reported by phpcs --standard=Drupal,DrupalPractice.

Added patch for function naming error in module file as reported by phpcs.

Remaining one warning as maintainer might need it in future code.
WARNING | Unused variable $fields.

Mutasim Al-Shoura made their first commit to this issue’s fork.

  • 8f74ff8b committed on 1.0.x
    Issue #3360695 by Kaustab_Roy, urvashi_vora: Fix the issues reported by...

mutasim al-shoura’s picture

Thank you for the patches. It has been merged and some other improvements applied.

  • 8f74ff8b committed on 1.0.0
    Issue #3360695 by Kaustab_Roy, urvashi_vora: Fix the issues reported by...
mutasim al-shoura’s picture

Status: Needs review » Fixed
urvashi_vora’s picture

Hi @Mutasim,

I am curious to know why I haven't been credited for my contribution here, as I actively participated in identifying the issue with your module, creating the necessary ticket, and even providing a patch for its resolution. I was wondering if there is a specific reason for my exclusion from receiving credit.
I would greatly appreciate it if you could provide some clarification on this matter.

Thanks

mutasim al-shoura’s picture

Hi @urvashi_vora

Yes sorry about that it's by mistake, I assure you that I'll credit you and @Kaustab_Roy for your valuable contribution ASAP.

Thank you

urvashi_vora’s picture

Thank You

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.