Removed unnecessary translation string for 'graph' from several cgis

Message ID 20200513134453.29982-1-matthias.fischer@ipfire.org
State New
Headers show
Series
  • Removed unnecessary translation string for 'graph' from several cgis
Related show

Commit Message

Matthias Fischer May 13, 2020, 1:44 p.m. UTC
The translation string $Lang::tr{'graph'} is unnecessary, because
everyone who opens the appropriate GUI should know that he will see: Graphs.

So we don't need to translate this twenty-two times for each affected cgi.

Signed-off-by: Matthias Fischer <matthias.fischer@ipfire.org>
---
 html/cgi-bin/hardwaregraphs.cgi | 10 +++++-----
 html/cgi-bin/media.cgi          |  2 +-
 html/cgi-bin/memory.cgi         |  4 ++--
 html/cgi-bin/netexternal.cgi    |  2 +-
 html/cgi-bin/netinternal.cgi    |  4 ++--
 html/cgi-bin/netother.cgi       |  4 ++--
 html/cgi-bin/netovpnrw.cgi      |  2 +-
 html/cgi-bin/netovpnsrv.cgi     |  2 +-
 html/cgi-bin/qos.cgi            |  4 ++--
 html/cgi-bin/services.cgi       |  4 ++--
 html/cgi-bin/system.cgi         |  6 +++---
 11 files changed, 22 insertions(+), 22 deletions(-)

Patch

diff --git a/html/cgi-bin/hardwaregraphs.cgi b/html/cgi-bin/hardwaregraphs.cgi
index e582acfb9..6c167f8cc 100644
--- a/html/cgi-bin/hardwaregraphs.cgi
+++ b/html/cgi-bin/hardwaregraphs.cgi
@@ -104,31 +104,31 @@  if ( $querry[0] =~ "hwtemp"){
 		chomp $disk;
 		my @array = split(/\//,$disk);
 
-		&Header::openbox('100%', 'center', "$array[$#array] $Lang::tr{'graph'}");
+		&Header::openbox('100%', 'center', "$array[$#array]");
 		&Graphs::makegraphbox("hardwaregraphs.cgi",$array[$#array],"day");
 		&Header::closebox();
 	}
 
 	if ( `ls $mainsettings{'RRDLOG'}/collectd/localhost/thermal-thermal_zone* 2>/dev/null` ) {
-		&Header::openbox('100%', 'center', "ACPI Thermal-Zone Temp $Lang::tr{'graph'}");
+		&Header::openbox('100%', 'center', "ACPI Thermal-Zone Temp");
 		&Graphs::makegraphbox("hardwaregraphs.cgi","thermaltemp","day");
 		&Header::closebox();
 	}
 
 	if ( `ls $mainsettings{'RRDLOG'}/collectd/localhost/sensors-*/temperature-* 2>/dev/null` ) {
-		&Header::openbox('100%', 'center', "hwtemp $Lang::tr{'graph'}");
+		&Header::openbox('100%', 'center', "hwtemp");
 		&Graphs::makegraphbox("hardwaregraphs.cgi","hwtemp","day");
 		Header::closebox();
 	}
 
 	if ( `ls $mainsettings{'RRDLOG'}/collectd/localhost/sensors-*/fanspeed-* 2>/dev/null` ) {
-		&Header::openbox('100%', 'center', "hwfan $Lang::tr{'graph'}");
+		&Header::openbox('100%', 'center', "hwfan");
 		&Graphs::makegraphbox("hardwaregraphs.cgi","hwfan","day");
 		&Header::closebox();
 	}
 
 	if ( `ls $mainsettings{'RRDLOG'}/collectd/localhost/sensors-*/voltage-* 2>/dev/null` ) {
-		&Header::openbox('100%', 'center', "hwvolt $Lang::tr{'graph'}");
+		&Header::openbox('100%', 'center', "hwvolt");
 		&Graphs::makegraphbox("hardwaregraphs.cgi","hwvolt","day");
 		&Header::closebox();
 	}
diff --git a/html/cgi-bin/media.cgi b/html/cgi-bin/media.cgi
index 5753bc301..0bb6435ab 100644
--- a/html/cgi-bin/media.cgi
+++ b/html/cgi-bin/media.cgi
@@ -61,7 +61,7 @@  if ( $querry[0] =~ "sd?" || $querry[0] =~ "mmcblk?" || $querry[0] =~ "nvme?n?" |
 		my $device = $_;
 		chomp($device);
 		my @array = split(/\//,$device);
-		&Header::openbox('100%', 'center', "$array[$#array] $Lang::tr{'graph'}");
+		&Header::openbox('100%', 'center', "$array[$#array]");
 		diskbox($array[$#array]);
 		&Graphs::makegraphbox("media.cgi",$array[$#array],"day");
 		&Header::closebox();
diff --git a/html/cgi-bin/memory.cgi b/html/cgi-bin/memory.cgi
index 1708b0f32..a06e62512 100644
--- a/html/cgi-bin/memory.cgi
+++ b/html/cgi-bin/memory.cgi
@@ -52,12 +52,12 @@  if ( $querry[0] =~ "memory"){
 	&Header::openpage($Lang::tr{'memory information'}, 1, '');
 	&Header::openbigbox('100%', 'left');
 
-	&Header::openbox('100%', 'center', "Memory $Lang::tr{'graph'}");
+	&Header::openbox('100%', 'center', "$Lang::tr{'memory'}");
 	&Graphs::makegraphbox("memory.cgi","memory","day");
 	&Header::closebox();
 
 	if ( `ls $mainsettings{'RRDLOG'}/collectd/localhost/swap 2>/dev/null` ) {
-	    &Header::openbox('100%', 'center', "Swap $Lang::tr{'graph'}");
+	    &Header::openbox('100%', 'center', "Swap");
 	    &Graphs::makegraphbox("memory.cgi","swap","day");
 	    &Header::closebox();
 	}
diff --git a/html/cgi-bin/netexternal.cgi b/html/cgi-bin/netexternal.cgi
index 98ac4fe12..ab94ca315 100644
--- a/html/cgi-bin/netexternal.cgi
+++ b/html/cgi-bin/netexternal.cgi
@@ -75,7 +75,7 @@  if ( $querry[0] ne~ ""){
 	}
 
 	foreach (@graphs) {
-		&Header::openbox('100%', 'center', "$_ $Lang::tr{'graph'}");
+		&Header::openbox('100%', 'center', "$_");
 		&Graphs::makegraphbox("netexternal.cgi",$_,"day");
 		&Header::closebox();
 	}
diff --git a/html/cgi-bin/netinternal.cgi b/html/cgi-bin/netinternal.cgi
index 3f2fb56cc..b6926d0c9 100644
--- a/html/cgi-bin/netinternal.cgi
+++ b/html/cgi-bin/netinternal.cgi
@@ -71,13 +71,13 @@  if ( $querry[0] =~ /wireless/ ){
 	}
 
 	foreach (@graphs) {
-		&Header::openbox('100%', 'center', "$_ $Lang::tr{'graph'}");
+		&Header::openbox('100%', 'center', "$_");
 		&Graphs::makegraphbox("netinternal.cgi",$_,"day");
 		&Header::closebox();
 	}
 
 	foreach (@wireless) {
-		&Header::openbox('100%', 'center', "Wireless $_ $Lang::tr{'graph'}");
+		&Header::openbox('100%', 'center', "Wireless $_");
 		&Graphs::makegraphbox("netinternal.cgi","wireless".$_,"day");
 		&Header::closebox();
 	}
diff --git a/html/cgi-bin/netother.cgi b/html/cgi-bin/netother.cgi
index 4f03c82e8..0b36a96d1 100755
--- a/html/cgi-bin/netother.cgi
+++ b/html/cgi-bin/netother.cgi
@@ -62,12 +62,12 @@  if ( $querry[0] =~ "fwhits"){
 	}
 
 	foreach (@pings) {
-		&Header::openbox('100%', 'center', "$_ $Lang::tr{'graph'}");
+		&Header::openbox('100%', 'center', "$_");
 		&Graphs::makegraphbox("netother.cgi",$_,"day");
 		&Header::closebox();
 	}
 
-	&Header::openbox('100%', 'center', "$Lang::tr{'firewallhits'} $Lang::tr{'graph'}");
+	&Header::openbox('100%', 'center', "$Lang::tr{'firewallhits'}");
 	&Graphs::makegraphbox("netother.cgi","fwhits","day");
 	&Header::closebox();
 
diff --git a/html/cgi-bin/netovpnrw.cgi b/html/cgi-bin/netovpnrw.cgi
index cae7770bb..fc0307a33 100755
--- a/html/cgi-bin/netovpnrw.cgi
+++ b/html/cgi-bin/netovpnrw.cgi
@@ -58,7 +58,7 @@  if ( $querry[0] ne "" && $querry[0] ne "UNDEF"){
 	}
 	if(@vpns){
 		foreach (@vpns) {
-			&Header::openbox('100%', 'center', "$_ $Lang::tr{'graph'}");
+			&Header::openbox('100%', 'center', "$_");
 			&Graphs::makegraphbox("netovpnrw.cgi",$_, "day");
 			&Header::closebox();
 		}
diff --git a/html/cgi-bin/netovpnsrv.cgi b/html/cgi-bin/netovpnsrv.cgi
index 77c69cddb..c2a5531cd 100755
--- a/html/cgi-bin/netovpnsrv.cgi
+++ b/html/cgi-bin/netovpnsrv.cgi
@@ -80,7 +80,7 @@  if ( $querry[0] ne ""){
 		}
 
 		foreach (@vpns) {
-			&Header::openbox('100%', 'center', "$_ $Lang::tr{'graph'}");
+			&Header::openbox('100%', 'center', "$_");
 			&Graphs::makegraphbox("netovpnsrv.cgi",$_, "day");
 			&Header::closebox();
 		}
diff --git a/html/cgi-bin/qos.cgi b/html/cgi-bin/qos.cgi
index 8211a3ca0..e3b3eefb4 100644
--- a/html/cgi-bin/qos.cgi
+++ b/html/cgi-bin/qos.cgi
@@ -708,10 +708,10 @@  if ( ($qossettings{'DEFCLASS_INC'} eq '') || ($qossettings{'DEFCLASS_OUT'} eq ''
 	exit
 }
 
-	&Header::openbox('100%', 'center', "$qossettings{'RED_DEV'} $Lang::tr{'graph'}, $Lang::tr{'uplink'}");
+	&Header::openbox('100%', 'center', "$qossettings{'RED_DEV'} $Lang::tr{'uplink'}");
 	&Graphs::makegraphbox("qos.cgi",$qossettings{'RED_DEV'},"hour");
 	&Header::closebox();
-	&Header::openbox('100%', 'center', "$qossettings{'IMQ_DEV'} $Lang::tr{'graph'}, $Lang::tr{'downlink'}");
+	&Header::openbox('100%', 'center', "$qossettings{'IMQ_DEV'} $Lang::tr{'downlink'}");
 	&Graphs::makegraphbox("qos.cgi",$qossettings{'IMQ_DEV'},"hour");
 	&Header::closebox();
 
diff --git a/html/cgi-bin/services.cgi b/html/cgi-bin/services.cgi
index 26ab4f314..ca33c7285 100644
--- a/html/cgi-bin/services.cgi
+++ b/html/cgi-bin/services.cgi
@@ -204,11 +204,11 @@  END
 	print "</table></div>\n";
 	&Header::closebox();
 
-	&Header::openbox('100%', 'center', "$Lang::tr{'processes'} $Lang::tr{'graph'}");
+	&Header::openbox('100%', 'center', "$Lang::tr{'processes'}");
 	&Graphs::makegraphbox("services.cgi","processescpu","day");
 	&Header::closebox();
 
-	&Header::openbox('100%', 'center', "$Lang::tr{'processes'} $Lang::tr{'memory'} $Lang::tr{'graph'}");
+	&Header::openbox('100%', 'center', "$Lang::tr{'processes'} $Lang::tr{'memory'}");
 	&Graphs::makegraphbox("services.cgi","processesmemory","day");
 	&Header::closebox();
 
diff --git a/html/cgi-bin/system.cgi b/html/cgi-bin/system.cgi
index 0548dddda..3af4b8e01 100644
--- a/html/cgi-bin/system.cgi
+++ b/html/cgi-bin/system.cgi
@@ -56,17 +56,17 @@  if ( $querry[0] =~ "cpufreq"){
 	&Header::openpage($Lang::tr{'status information'}, 1, '');
 	&Header::openbigbox('100%', 'left');
 
-	&Header::openbox('100%', 'center', "CPU $Lang::tr{'graph'}");
+	&Header::openbox('100%', 'center', "CPU");
 	&Graphs::makegraphbox("system.cgi","cpu","day");
 	&Header::closebox();
 
 	if ( -e "$mainsettings{'RRDLOG'}/collectd/localhost/cpufreq/cpufreq-0.rrd"){
-		&Header::openbox('100%', 'center', "$Lang::tr{'cpu frequency'} $Lang::tr{'graph'}");
+		&Header::openbox('100%', 'center', "$Lang::tr{'cpu frequency'}");
 		&Graphs::makegraphbox("system.cgi","cpufreq","day");
 		&Header::closebox();
 	}
 
-	&Header::openbox('100%', 'center', "$Lang::tr{'uptime load average'} $Lang::tr{'graph'}");
+	&Header::openbox('100%', 'center', "$Lang::tr{'uptime load average'}");
 	&Graphs::makegraphbox("system.cgi","load","day");
 	&Header::closebox();