Closed (fixed)
Project:
Drupal.org security advisory coverage applications
Component:
module
Priority:
Normal
Category:
Task
Assigned:
Reporter:
Created:
9 Dec 2021 at 13:04 UTC
Updated:
4 Jan 2022 at 08:19 UTC
Jump to comment: Most recent
Comments
Comment #2
tonytheferg commentedComment #3
avpadernoComment #4
rajeshreeputraAt multiple places called t() function in .module file, which need to be fixed.
t() calls should be avoided in classes, use \Drupal\Core\StringTranslation\StringTranslationTrait and $this->t() insteadComment #5
avpadernoComment #6
tonytheferg commentedIt's not in a class, It's in a module file. Do you have an example of a module file that implements
$this->t()?Comment #7
tonytheferg commentedViews does the exact same thing in their module file:
Comment #8
avpadernoDrupal core is still calling
t()in procedural code, as functions cannot useStringTranslationTrait.I apologize: I misread the comment #4 and thought it was referring to a file used by the module, not to the .module itself. That's why I changed status.
Comment #9
tonytheferg commentedYup, no problem. I did however use it everywhere else. (the settings form, etc.)
Comment #10
avpadernoThank you for your contribution! I am going to update your account.
These are some recommended readings to help with excellent maintainership:
You can find more contributors chatting on the IRC #drupal-contribute channel. So, come hang out and stay involved.
Thank you, also, for your patience with the review process.
Anyone is welcome to participate in the review process. Please consider reviewing other projects that are pending review. I encourage you to learn more about that process and join the group of reviewers.