From c595f3095bd53e458984e410e24bf4d81a976aea Mon Sep 17 00:00:00 2001 From: Michael Marley Date: Sun, 12 Jul 2015 11:38:40 -0400 Subject: [PATCH] luci-app-vnstat: Fix blank graphs for iface names with underscores The regex used to process the iface query string argument in vnstat.htm was stripping underscores, which caused the graph not to display for interfaces with names containing underscores. This patch adds the underscore to that regex so that the interface name will be correct and the graph will be displayed. Signed-off-by: Michael Marley --- applications/luci-app-vnstat/luasrc/view/vnstat.htm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/luci-app-vnstat/luasrc/view/vnstat.htm b/applications/luci-app-vnstat/luasrc/view/vnstat.htm index cfa1a5de5..2b502559b 100644 --- a/applications/luci-app-vnstat/luasrc/view/vnstat.htm +++ b/applications/luci-app-vnstat/luasrc/view/vnstat.htm @@ -22,7 +22,7 @@ style = (style and #style > 0) and style or "s" -- if iface then style = style:gsub("[^%w]", "") - iface = iface:gsub("[^%w%.%-]", "") + iface = iface:gsub("[^%w%.%-%_]", "") luci.http.prepare_content("image/png") -- 2.25.1