Fix PHPCS warnings

Created on 1 November 2023, about 1 year ago
Updated 27 November 2023, 12 months ago

Problem/Motivation

During the migration to GitlabCI detected new PHPCS warnings.

https://git.drupalcode.org/project/layout_builder_lock/-/jobs/263174

šŸ“Œ Task
Status

Fixed

Version

1.0

Component

Code

Created by

šŸ‡ŗšŸ‡¦Ukraine Panchuk Volyn, Lutsk

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @Panchuk
  • Assigned to chetan 11
  • Merge request !16issue fixed ā†’ (Merged) created by chetan 11
  • Issue was unassigned.
  • Status changed to Needs review about 1 year ago
  • šŸ‡®šŸ‡³India chetan 11

    Hi Panchuk
    I have fixed all the phpcs issues in "Layout Builder Lock" module.
    please check the raised MR.
    Thanks

  • Status changed to Needs work about 1 year ago
  • šŸ‡ŗšŸ‡¦Ukraine Panchuk Volyn, Lutsk

    Hey @chatan-11

    Thanks for your contribution! I reviewed MR and found a few problems.

    PHPCS still failed in the layout_builder_lock.module file.
    https://git.drupalcode.org/issue/layout_builder_lock-3398496/-/jobs/264738

    | Hook implementations should not duplicate @param
    | documentation
    | (Drupal.Commenting.HookComment.HookParamDoc)

    These errors mean that the doc for hooks shouldn't contain any @param or @return props.

    Example:

    /**
    * Implements hook_element_info_alter().
    */

  • Status changed to Needs review about 1 year ago
  • Status changed to RTBC about 1 year ago
  • šŸ‡µšŸ‡­Philippines clarkssquared

    Hi chetan,

    I applied your updated MR !16 into my local and as I execute the PHPCS command its now flagged no PHPCS issues in the module

    āžœ  layout_builder_lock git:(4e0e049) curl https://git.drupalcode.org/project/layout_builder_lock/-/merge_requests/16.diff | patch -p1
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
    100 27084    0 27084    0     0  49795      0 --:--:-- --:--:-- --:--:-- 51984
    patching file README.md
    patching file 'js/layout-builder-lock.admin.js'
    patching file layout_builder_lock.module
    patching file 'src/Access/LayoutBuilderLockAccessCheck.php'
    patching file 'src/LayoutBuilderLock.php'
    patching file 'tests/src/Functional/LayoutBuilderLockTest.php'
    āžœ  layout_builder_lock git:(4e0e049) āœ— ..
    āžœ  contrib git:(master) āœ— phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml layout_builder_lock
                                                                                    
    āžœ  contrib git:(master) āœ— 
  • šŸ‡®šŸ‡³India chetan 11

    I have changed all the things as per the mention in comments.

  • Status changed to Fixed 12 months ago
  • šŸ‡ŗšŸ‡¦Ukraine Panchuk Volyn, Lutsk
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024