Added the ability to use printf(3) % variables in trans()

This commit is contained in:
Elijah Perrault committed 2011-02-14 20:55:49 -07:00
1 parent 934a10d880
commit 31e2c8b4f9
2 files changed
+3 -2

No files matched your search

+2 -2
View File
@@ -337,11 +337,11 @@ sub conf_get
# Translation subroutine.
sub trans
{
my ($id) = @_;
my $id = shift;
$id =~ s/ /_/gsm;
if (defined $API::Std::LANGE{$id}) {
return $API::Std::LANGE{$id};
return sprintf $API::Std::LANGE{$id}, @_;
}
else {
$id =~ s/_/ /gsm;