Fix the errors reported by PHPCS

Created on 8 August 2023, over 1 year ago
Updated 9 August 2023, over 1 year ago

Problem/Motivation

FILE: /var/www/html/web/modules/contrib/audio_embed_field-3379962/src/Plugin/Field/FieldWidget/AudioTextfield.php
-----------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
-----------------------------------------------------------------------------------------------------------------
29 | ERROR | [x] Use null coalesce operator instead of ternary operator.
-----------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------------------------------------

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

📌 Task
Status

Fixed

Version

2.0

Component

Code

Created by

🇮🇳India Nishant

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 @Nishant
  • First commit to issue fork.
  • Assigned to kpoornima
  • 🇮🇳India kpoornima

    I am looking on it

  • @kpoornima opened merge request.
  • Issue was unassigned.
  • Status changed to Needs review over 1 year ago
  • 🇮🇳India kpoornima

    Please review and Merge

  • Status changed to Needs work over 1 year ago
  • 🇵🇭Philippines roberttabigue

    Hi @kpoornima,

    When I applied your MR !3 to the Audio Embed Field module against 8.x-2.x-dev on Drupal 9.5.10, it didn't resolve all the errors.
    See the remaining 1 error below:

    FILE: /.../audio_embed_field/modules/audio_embed_media/audio_embed_media.info.yml
    --------------------------------------------------------------------------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    --------------------------------------------------------------------------------------------------------------------------------------------------
     1 | WARNING | "core_version_requirement" property is missing in the info.yml file
    --------------------------------------------------------------------------------------------------------------------------------------------------
    
    Time: 473ms; Memory: 10MB

    Please run this command on the module:
    phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml,twig audio_embed_field

    Moving this to Needs work for now.

    Thank you!

  • 🇮🇳India kpoornima

    HI @roberttabigue

    MR !3 Phpcs errors checked with 8.x-2.0 and updated ticket version with 8.x-2.0.

    Thanks You!

  • Status changed to Fixed over 1 year ago
Production build 0.71.5 2024