t() calls should be avoided in classes

Created on 28 February 2023, over 1 year ago
Updated 12 April 2023, over 1 year ago

Problem/Motivation

t() calls should be avoided in classes, use
| | \Drupal\Core\StringTranslation\StringTranslationTrait and
| | $this->t() instead

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 auto_node_translate/

Proposed resolution

Fix all the issues

and verify it using
phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,js,info,txt,md,yml,twig auto_node_translate/

It should not give any errors.

📌 Task
Status

Fixed

Version

2.1

Component

Code

Created by

🇮🇳India urvashi_vora Madhya Pradesh, India

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

Comments & Activities

Production build 0.71.5 2024