[1.0.2] Fix the issues reported by phpcs

Created on 30 May 2023, over 1 year ago
Updated 12 April 2024, 7 months ago

Problem/Motivation

FILE: ...ribution/drupal10/web/modules/contrib/ckeditor_autocomplete_link/README.md
--------------------------------------------------------------------------------
FOUND 0 ERRORS AND 9 WARNINGS AFFECTING 9 LINES
--------------------------------------------------------------------------------
3 | WARNING | Line exceeds 80 characters; contains 89 characters
6 | WARNING | Line exceeds 80 characters; contains 127 characters
11 | WARNING | Line exceeds 80 characters; contains 84 characters
23 | WARNING | Line exceeds 80 characters; contains 119 characters
39 | WARNING | Line exceeds 80 characters; contains 103 characters
49 | WARNING | Line exceeds 80 characters; contains 115 characters
56 | WARNING | Line exceeds 80 characters; contains 114 characters
60 | WARNING | Line exceeds 80 characters; contains 117 characters
61 | WARNING | Line exceeds 80 characters; contains 116 characters
--------------------------------------------------------------------------------

FILE: ...r_autocomplete_link/src/Plugin/CKEditorPlugin/CKEditorAutocompleteLink.php
--------------------------------------------------------------------------------
FOUND 4 ERRORS AFFECTING 4 LINES
--------------------------------------------------------------------------------
19 | ERROR | [ ] Missing short description in doc comment
20 | ERROR | [x] Data types in @var tags need to be fully namespaced
24 | ERROR | [ ] Missing member variable doc comment
89 | ERROR | [x] Expected 1 newline at end of file; 2 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: .../contrib/ckeditor_autocomplete_link/src/CKEditorAutocompleteLinkHelper.php
--------------------------------------------------------------------------------
FOUND 4 ERRORS AFFECTING 4 LINES
--------------------------------------------------------------------------------
15 | ERROR | [ ] Doc comment short description must be on a single line,
| | further text should be a separate paragraph
18 | ERROR | [x] Parameter comment indentation must be 3 spaces, found 2
| | spaces
21 | ERROR | [x] Return comment indentation must be 3 spaces, found 1 spaces
41 | ERROR | [x] Object operator not indented correctly; expected 12 spaces
| | but found 14
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...dules/contrib/ckeditor_autocomplete_link/ckeditor_autocomplete_link.module
--------------------------------------------------------------------------------
FOUND 11 ERRORS AND 3 WARNINGS AFFECTING 14 LINES
--------------------------------------------------------------------------------
10 | WARNING | [x] Unused use statement
13 | WARNING | [x] Unused use statement
14 | WARNING | [x] Unused use statement
25 | ERROR | [x] Concat operator must be surrounded by a single space
40 | ERROR | [x] Expected 1 blank line after function; 0 found
49 | ERROR | [x] Data types in @var tags need to be fully namespaced
52 | ERROR | [x] Data types in @var tags need to be fully namespaced
55 | ERROR | [x] Data types in @var tags need to be fully namespaced
73 | ERROR | [x] Array indentation error, expected 4 spaces but found 2
74 | ERROR | [x] Array indentation error, expected 4 spaces but found 2
101 | ERROR | [ ] Missing parameter comment
102 | ERROR | [ ] Missing parameter comment
106 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
110 | ERROR | [x] Expected 1 newline at end of file; 3 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 12 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

Time: 434ms; 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 ckeditor_autocomplete_link/

Remaining tasks

Patch review.

📌 Task
Status

Fixed

Version

1.0

Component

Code

Created by

🇮🇳India urvashi_vora Madhya Pradesh, India

Live updates comments and jobs are added and updated live.
  • Coding standards

    It involves compliance with, or the content of coding standards. Requires broad community agreement.

Sign in to follow issues

Comments & Activities

  • Issue created by @urvashi_vora
  • Status changed to Needs work over 1 year ago
  • 🇵🇭Philippines kenyoOwen

    Hi urvashi_vora

    After I applied your patch, there are still errors and warnings remaining.

    FILE: /Users/studenttrainees/Project10/drupalorg10/docroot/modules/contrib/ckeditor_autocomplete_link/ckeditor_autocomplete_link.info.yml
    -----------------------------------------------------------------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 3 WARNINGS AFFECTING 1 LINE
    -----------------------------------------------------------------------------------------------------------------------------------------
    1 | WARNING | Remove "project" from the info file, it will be added by drupal.org packaging automatically
    1 | WARNING | Remove "datestamp" from the info file, it will be added by drupal.org packaging automatically
    1 | WARNING | Remove "version" from the info file, it will be added by drupal.org packaging automatically
    -----------------------------------------------------------------------------------------------------------------------------------------

    FILE: /Users/studenttrainees/Project10/drupalorg10/docroot/modules/contrib/ckeditor_autocomplete_link/ckeditor_autocomplete_link.module
    ---------------------------------------------------------------------------------------------------------------------------------------
    FOUND 1 ERROR AFFECTING 1 LINE
    ---------------------------------------------------------------------------------------------------------------------------------------
    72 | ERROR | [x] Use null coalesce operator instead of ternary operator.
    ---------------------------------------------------------------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    ---------------------------------------------------------------------------------------------------------------------------------------

    FILE: /Users/studenttrainees/Project10/drupalorg10/docroot/modules/contrib/ckeditor_autocomplete_link/src/Plugin/CKEditorPlugin/CKEditorAutocompleteLink.php
    ------------------------------------------------------------------------------------------------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 2 LINES
    ------------------------------------------------------------------------------------------------------------------------------------------------------------
    64 | ERROR | [x] Use null coalesce operator instead of ternary operator.
    89 | ERROR | [x] Use null coalesce operator instead of ternary operator.
    ------------------------------------------------------------------------------------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    ------------------------------------------------------------------------------------------------------------------------------------------------------------

    Time: 273ms; Memory: 10MB

    Please check
    Thank you

  • Status changed to Needs review over 1 year ago
  • 🇮🇳India mrinalini9 New Delhi

    Updated patch #1 by addressing #2, please review it.

    Thanks!

  • Status changed to RTBC 8 months ago
  • 🇮🇳India Ashutosh Ahirwal India

    Hi I reviewed #3 patch it get applied cleanly and no error found.
    Moving to RTBC

  • Status changed to Fixed 8 months ago
  • 🇷🇪Réunion Martygraphie Saint-Denis (Réunion)

    Hello,
    Thank you all for your work, I credit everyone for your work.

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

Production build 0.71.5 2024