Fix the issues reported by phpcs

Created on 15 May 2023, over 1 year ago
Updated 20 July 2023, over 1 year ago

Problem/Motivation

Module's code contains several Drupal Coding Standards issues. This task is created to fix them.

Steps to reproduce

Run phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,js,info,txt,md,yml,twig ./cron_fail_alert_1.0.x.

Proposed resolution

Fix the following coding standards issues and upload the patch or create an MR with fixes.

FILE: ./cron_fail_alert_1.0.x/src/EventSubscriber/CronFailAlertSubscriber.php
---------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
---------------------------------------------------------------------------------------------------------------
 13 | WARNING | [x] Unused use statement
---------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
---------------------------------------------------------------------------------------------------------------

Time: 126ms; Memory: 10MB

📌 Task
Status

Closed: outdated

Version

1.0

Component

Code

Created by

🇮🇳India Shanu Chouhan

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 @Shanu Chouhan
  • Issue was unassigned.
  • Status changed to Needs review over 1 year ago
  • 🇮🇳India Shanu Chouhan

    I have Created a patch to fix this issue.

  • Status changed to Needs work over 1 year ago
  • 🇮🇹Italy apaderno Brescia, 🇮🇹

    If I run phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,js,info,txt,md,yml,twig ./cron_fail_alert_1.0.x for the 1.0.x branch, I get a single warning.

  • Status changed to Needs review over 1 year ago
  • 🇮🇳India arpitk

    I tried the patch #2 and it applied cleanly. Running phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,js,info,txt,md,yml,twig for 1.0.x. Attached screenshot.

    Thanks!

  • 🇮🇹Italy apaderno Brescia, 🇮🇹
  • Status changed to Closed: outdated over 1 year ago
  • 🇮🇳India Hemangi Gokhale

    This issue is no longer relevant, as the fix has been implemented.

Production build 0.71.5 2024