t() calls should be avoided in classes

Created on 24 July 2023, over 1 year ago

Problem/Motivation

t() calls should be avoided in classes, use $this->t() instead

Proposed resolution


FILE: /modules/contrib/permissions_visibility_filter/src/Form/PvfConfigForm.php
----------------------------------------------------------------------------------------------------------------------------------------------

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

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

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

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

-----------------------------------------------------------------------------------------------------------------------------------------------
📌 Task
Status

Closed: works as designed

Component

Code

Created by

🇮🇳India swatichouhan012

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

    Hello,

    I have created a patch to solve the errors related to t() calls .

    Please review and apply it .

  • Status changed to Closed: works as designed over 1 year ago
  • 🇺🇸United States bnjmnm Ann Arbor, MI

    As the maintainer of this project, I am not interested in coding standard fixes based on automated checks being in this queue.

    This module is barely past the proof of concept stage and these kind of issues are pointless until it is more fully formed. A dedicated issue making superficial code changes for a work-in-progress module that nobody uses is just noise. When this module is actually ready for release the code can get cleaned up in a single non-credit-earning commit.

Production build 0.71.5 2024