diff --git a/templates/Classic/admin/traffic/index.tpl b/templates/Classic/admin/traffic/index.tpl index 2fa45f74..7a3239fc 100644 --- a/templates/Classic/admin/traffic/index.tpl +++ b/templates/Classic/admin/traffic/index.tpl @@ -4,13 +4,13 @@ $header $.tablesorter.addParser( { id: 'filesize', is: function(s) { - return s.match( new RegExp( /[0-9]+(\.[0-9]+)?\ (KiB|Bi|GiB|MiB|TiB)/ ) ); + return s.match( new RegExp( /[0-9]+(\.[0-9]+)?\ (KiB|B|GiB|MiB|TiB)/ ) ); }, format: function(s) { - var suf = s.match( new RegExp( /(KiB|Bi|GiB|MiB|TiB)/) )[1]; + var suf = s.match( new RegExp( /(KiB|B|GiB|MiB|TiB)/) )[1]; var num = parseFloat( s.match( new RegExp( /^[0-9]+(\.[0-9]+)?/ ) )[0] ); switch( suf ) { - case 'Bi': + case 'B': return num; case 'KiB': return num * 1024; diff --git a/templates/Froxlor/admin/traffic/index.tpl b/templates/Froxlor/admin/traffic/index.tpl index 312557fd..20b6d4a9 100644 --- a/templates/Froxlor/admin/traffic/index.tpl +++ b/templates/Froxlor/admin/traffic/index.tpl @@ -4,13 +4,13 @@ $header $.tablesorter.addParser( { id: 'filesize', is: function(s) { - return s.match( new RegExp( /[0-9]+(\.[0-9]+)?\ (KiB|Bi|GiB|MiB|TiB)/ ) ); + return s.match( new RegExp( /[0-9]+(\.[0-9]+)?\ (KiB|B|GiB|MiB|TiB)/ ) ); }, format: function(s) { - var suf = s.match( new RegExp( /(KiB|Bi|GiB|MiB|TiB)/) )[1]; + var suf = s.match( new RegExp( /(KiB|B|GiB|MiB|TiB)/) )[1]; var num = parseFloat( s.match( new RegExp( /^[0-9]+(\.[0-9]+)?/ ) )[0] ); switch( suf ) { - case 'Bi': + case 'B': return num; case 'KiB': return num * 1024;