--------------------------------------------------------------------------------------------------------------------
FOUND 8 ERRORS AFFECTING 7 LINES
--------------------------------------------------------------------------------------------------------------------
 126 | ERROR | [x] Expected 1 blank line after function; 3 found
 129 | ERROR | [ ] More than 2 empty lines are not allowed
 130 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 3
 131 | ERROR | [x] Expected 4 space(s) before asterisk; 3 found
 132 | ERROR | [x] Expected 4 space(s) before asterisk; 3 found
 187 | ERROR | [x] Expected 1 space after IF keyword; 0 found
 187 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
 412 | ERROR | [x] Expected 1 newline at end of file; 2 found
--------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 7 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------------------------------------------

Time: 367ms; Memory: 10MB
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

Sahana _N created an issue. See original summary.

sahana _n’s picture

Status: Active » Needs review
StatusFileSize
new1.06 KB

Please review the patch.

sidharth_soman’s picture

Assigned: Unassigned » sidharth_soman
Status: Needs review » Needs work

Patch doesn't apply anymore due to the updates on the branch. I'll upload a new one.

sidharth_soman’s picture

StatusFileSize
new15.4 KB

Attaching a screenshot for reference.

sidharth_soman’s picture

Assigned: sidharth_soman » Unassigned
Status: Needs work » Needs review
Issue tags: +Coding standards
StatusFileSize
new1.71 KB

New issues on 9.1.x were:


C:\xampp\htdocs\backendassignment\web\modules\contrib>phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml,twig rest_mail_login

FILE: C:\xampp\htdocs\backendassignment\web\modules\contrib\rest_mail_login\README.md
-------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
-------------------------------------------------------------------------------------
 5 | ERROR | [x] Expected 1 newline at end of file; 0 found
-------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-------------------------------------------------------------------------------------


FILE: C:\xampp\htdocs\backendassignment\web\modules\contrib\rest_mail_login\src\Controller\RestMailLoginController.php
----------------------------------------------------------------------------------------------------------------------
FOUND 8 ERRORS AFFECTING 6 LINES
----------------------------------------------------------------------------------------------------------------------
  1 | ERROR | [x] The PHP open tag must be followed by exactly one blank line
  1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
  2 | ERROR | [x] There must be one blank line after the namespace declaration
 29 | ERROR | [x] Expected 1 space after IF keyword; 0 found
 29 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
 34 | ERROR | [x] Expected one space after the comma, 0 found
 47 | ERROR | [x] Expected 1 blank line after function; 0 found
 48 | ERROR | [x] The closing brace for the class must have an empty line before it
----------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 8 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------------------------------------------------------

Time: 594ms; Memory: 6MB

I've fixed them and uploaded a patch.

silvi.addweb made their first commit to this issue’s fork.

a.aaronjake’s picture

Status: Needs review » Reviewed & tested by the community

Hi @everyone,

Applied the patch #5 and also applied the MR !2, both were applied successfully and confirmed both fixed all errors.

Patch #5:

rest_mail_login git:(9.1.x) curl https://www.drupal.org/files/issues/2023-07-07/3203012-5.patch | patch -p1
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  1750  100  1750    0     0   7358      0 --:--:-- --:--:-- --:--:--  7882
patching file README.md
patching file src/Controller/RestMailLoginController.php
➜  rest_mail_login git:(9.1.x) ✗ cd ..
➜  contrib git:(main) ✗ phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml,twig rest_mail_login
➜  contrib git:(main) ✗

MR !2:

rest_mail_login git:(9.1.x) curl https://git.drupalcode.org/project/rest_mail_login/-/merge_requests/2.diff | patch -p1
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  1882    0  1882    0     0   3880      0 --:--:-- --:--:-- --:--:--  3987
patching file README.md
patching file src/Controller/RestMailLoginController.php
➜  rest_mail_login git:(9.1.x) ✗ cd ..
➜  contrib git:(main) ✗ phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml,twig rest_mail_login
➜  contrib git:(main) ✗

Will now move this to RTBC

Thanks,
Jake