Download & Extend

Bad usage of t() function

Project:View Alias
Version:6.x-2.2
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:reviewed & tested by the community

Issue Summary

There should be no variables in the translatable string. Please use the placeholders to make your strings more secure and translatable.

78:   $objects["$alias->path"] = t("View page displays having a path of '$alias->path'");
108: '#title' => t("View $alias->view_name, display $alias->display_name, on path $alias->path, with $voc->name arguments."),

Comments

#1

Status:active» needs review

Patch includes also a dozen of whitespace fixes.

AttachmentSize
1195042-1_bad_usage_of_t.patch 14.67 KB

#2

Almost same as #1, changed just one line - more appropriate placeholders.

- '#title' => t('View @view, display @display, on path @path, with @vocabulary arguments.', array('@view' => $alias->view_name,...
+ '#title' => t('View %view, display %display, on path %path, with %vocabulary arguments.', array('%view' => $alias->view_name,...
AttachmentSize
1195042-2_bad_usage_of_t.patch 14.67 KB

#3

Version:6.x-2.2» 6.x-2.x-dev

#5

Version:6.x-2.x-dev» 6.x-2.2

i rerolled this, seemed to be some issues applying it to dev. I'm applying it to 2.x

AttachmentSize
1195042-3_bad_usage_of_t.patch 7.19 KB

#6

Status:needs review» reviewed & tested by the community
nobody click here