[05/19] ovpnclients.dat: Display traffic details in a human-readable format.

Message ID 20200413074550.2735-5-stefan.schantl@ipfire.org
State Accepted
Commit 86153838235fd78863c51793b5285661710bd583
Headers show
Series [01/19] openvpn: Add WUI page for client usage statistics | expand

Commit Message

Stefan Schantl April 13, 2020, 7:45 a.m. UTC
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
---
 html/cgi-bin/logs.cgi/ovpnclients.dat | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Patch

diff --git a/html/cgi-bin/logs.cgi/ovpnclients.dat b/html/cgi-bin/logs.cgi/ovpnclients.dat
index bb7bdfb7b..b601fd292 100755
--- a/html/cgi-bin/logs.cgi/ovpnclients.dat
+++ b/html/cgi-bin/logs.cgi/ovpnclients.dat
@@ -250,8 +250,8 @@  while(my @row = $statement_handle->fetchrow_array()) {
 	my $connection_name = $row[0];
 	my $connection_open_time = $row[1];
 	my $connection_close_time = $row[2];
-	my $connection_bytes_recieved = $row[3];
-	my $connection_bytes_sent = $row[4];
+	my $connection_bytes_recieved = &General::formatBytes($row[3]);
+	my $connection_bytes_sent = &General::formatBytes($row[4]);
 
 	# Colorize columns. 
 	if ($lines % 2) {