luci-app-vpnbypass: fix dispatcher bug when VPN node is present
Signed-off-by: Stan Grishin <stangri@melmac.net>
This commit is contained in:
parent
68190f43ca
commit
444b1c126e
2 changed files with 6 additions and 2 deletions
|
@ -10,7 +10,7 @@ LUCI_TITLE:=VPN Bypass Web UI
|
||||||
LUCI_DESCRIPTION:=Provides Web UI for VPNBypass service.
|
LUCI_DESCRIPTION:=Provides Web UI for VPNBypass service.
|
||||||
LUCI_DEPENDS:=+luci-mod-admin-full +vpnbypass
|
LUCI_DEPENDS:=+luci-mod-admin-full +vpnbypass
|
||||||
LUCI_PKGARCH:=all
|
LUCI_PKGARCH:=all
|
||||||
PKG_RELEASE:=9
|
PKG_RELEASE:=10
|
||||||
|
|
||||||
include ../../luci.mk
|
include ../../luci.mk
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,11 @@ function en.write()
|
||||||
sys.init.enable(packageName)
|
sys.init.enable(packageName)
|
||||||
sys.init.start(packageName)
|
sys.init.start(packageName)
|
||||||
end
|
end
|
||||||
|
if dispatcher.lookup("admin/vpn") then
|
||||||
|
http.redirect(dispatcher.build_url("admin/vpn/" .. packageName))
|
||||||
|
else
|
||||||
http.redirect(dispatcher.build_url("admin/services/" .. packageName))
|
http.redirect(dispatcher.build_url("admin/services/" .. packageName))
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
s = m:section(NamedSection, "config", "vpnbypass", translate("VPN Bypass Rules"))
|
s = m:section(NamedSection, "config", "vpnbypass", translate("VPN Bypass Rules"))
|
||||||
|
|
Loading…
Reference in a new issue