Problem/Motivation

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

Proposed resolution

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

FILE: C:\modules\contrib\webform_inline_entity_form\src\Plugin\WebformElement\WebformInlineEntityForm.php
-----------------------------------------------------------------------------------------------
 169 | WARNING | [ ] t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 172 | WARNING | [ ] t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 173 | WARNING | [ ] t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 175 | WARNING | [ ] t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 179 | WARNING | [ ] t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 182 | WARNING | [ ] t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 183 | WARNING | [ ] t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead
 194 | WARNING | [ ] t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() instead

Comments

Shanu Chouhan created an issue. See original summary.

shanu chouhan’s picture

Assigned: shanu chouhan » Unassigned
Status: Active » Needs review
StatusFileSize
new1.69 KB

I have Created a patch to fix this issue.

kenyoowen’s picture

Status: Needs review » Reviewed & tested by the community
StatusFileSize
new222.14 KB
new260.89 KB

Hi Shanu Chouhan

I applied patch#2 and confirmed it fixed the issue mentioned. Please see the screenshots attached.

For your review.
Thank you.