diff --git a/emhttp/plugins/dynamix/WG0.page b/emhttp/plugins/dynamix/WG0.page index 29419de2d..79deb69cf 100644 --- a/emhttp/plugins/dynamix/WG0.page +++ b/emhttp/plugins/dynamix/WG0.page @@ -1032,14 +1032,13 @@ tstate['wg0'] = "=$check_wg0 ? 'active' : 'passive'?>"; var statistics = new NchanSubscriber('/sub/wireguard',{subscriber:'websocket'}); statistics.on('message', function(data) { - var list = []; - var rows = data.split('\0'); + var list = [], n = []; var x = 0; var vtun = ''; // get all existing tunnels $('div[id^="block-wg"]').each(function(){list.push($(this).prop('id').split('-')[1]);}); // update active tunnels - for (var i=0,row; row=rows[i]; i++) { - var info = row.split(';'); + var rows = JSON.parse(data); + for (var i=0,info; info=rows[i]; i++) { if (info[0] != vtun) { vtun = info[0]; // remove tunnel from inactive list @@ -1281,7 +1280,7 @@ _(Local tunnel address IPv6)_: _(Local endpoint)_: -: : +: : @@ -1318,7 +1317,7 @@ _(Local tunnel firewall)_: :wg_local_tunnel_firewall_help: _(MTU size)_: -: _(bytes)_ +: _(bytes)_ :wg_mtu_size_help: @@ -1362,7 +1361,7 @@ _(Peer type of access)_: =mk_option(_var($wg0,"TYPE:$i"), "7", _("VPN tunneled access for system"),count($peer_wg0)==1?'':'disabled')?> =mk_option(_var($wg0,"TYPE:$i"), "8", _("VPN tunneled access for docker"),count($peer_wg0)==1?'':'disabled')?> - + > ?>) diff --git a/emhttp/plugins/dynamix/WGX.page b/emhttp/plugins/dynamix/WGX.page index 184c4ecd0..c670515f6 100644 --- a/emhttp/plugins/dynamix/WGX.page +++ b/emhttp/plugins/dynamix/WGX.page @@ -224,7 +224,7 @@ _(Local tunnel address IPv6)_: _(Local endpoint)_: -: : +: : @@ -261,7 +261,7 @@ _(Local tunnel firewall)_: :wg_local_tunnel_firewall_help: _(MTU size)_: -: _(bytes)_ +: _(bytes)_ :wg_mtu_size_help: @@ -305,7 +305,7 @@ _(Peer type of access)_: =mk_option(_var($wgX,"TYPE:$i"), "7", _("VPN tunneled access for system"),count($peer_wgX)==1?'':'disabled')?> =mk_option(_var($wgX,"TYPE:$i"), "8", _("VPN tunneled access for docker"))?> - + > ?>) diff --git a/emhttp/plugins/dynamix/nchan/device_list b/emhttp/plugins/dynamix/nchan/device_list index 1d5915d03..e1d4ee083 100755 --- a/emhttp/plugins/dynamix/nchan/device_list +++ b/emhttp/plugins/dynamix/nchan/device_list @@ -151,7 +151,7 @@ function vfs_type(&$disk) { function fs_info(&$disk) { global $display; $echo = []; - if (empty($disk['fsStatus']) || $disk['fsStatus']=='-') + if (empty(_var($disk, 'fsStatus')) || _var($disk, 'fsStatus') == '-') return "