Drupal Coding Standards Issues | phpcs

Created on 2 January 2023, over 1 year ago
Updated 18 January 2023, over 1 year ago

Problem/Motivation

Getting following error.

FILE: /app/modules/contrib/entity_redirect/entity_redirect.module
---------------------------------------------------------------------------
FOUND 5 ERRORS AFFECTING 5 LINES
---------------------------------------------------------------------------
98 | ERROR | [x] Use null coalesce operator instead of ternary operator.
106 | ERROR | [x] Use null coalesce operator instead of ternary operator.
113 | ERROR | [x] Use null coalesce operator instead of ternary operator.
126 | ERROR | [x] Use null coalesce operator instead of ternary operator.
143 | ERROR | [x] Use null coalesce operator instead of ternary operator.
---------------------------------------------------------------------------
PHPCBF CAN FIX THE 5 MARKED SNIFF VIOLATIONS AUTOMATICALLY
---------------------------------------------------------------------------

Time: 219ms; Memory: 12MB

Steps to reproduce

Run following command

phpcs --standard="Drupal,DrupalPractice" --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml modules/contrib/entity_redirect/

Proposed resolution

Above error need to be fixed

🐛 Bug report
Status

Fixed

Version

2.0

Component

Code

Created by

🇮🇳India samit.310@gmail.com

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

No activities found.

Production build 0.69.0 2024