diff options
author | Jo-Philipp Wich <jo@mein.io> | 2019-11-08 16:03:09 +0100 |
---|---|---|
committer | Jo-Philipp Wich <jo@mein.io> | 2019-11-08 16:03:09 +0100 |
commit | 6496ed88a6dfa15c0f34f3865a559e1c405cdc4f (patch) | |
tree | 1dd3cc11b4b33b81c15dadf904294214ed1cfaab /applications/luci-app-openvpn | |
parent | 1116575513d4874693f56453034e25edcbb4ce1f (diff) |
luci-app-openvpn: do not make "remote" option dependent on client mode
Fixes: #3279
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'applications/luci-app-openvpn')
-rw-r--r-- | applications/luci-app-openvpn/luasrc/model/cbi/openvpn-advanced.lua | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-advanced.lua b/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-advanced.lua index 1971400b8..c310efc11 100644 --- a/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-advanced.lua +++ b/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-advanced.lua @@ -497,8 +497,7 @@ local knownParams = { { DynamicList, "remote", "1.2.3.4", - translate("Remote host name or ip address"), - { client="1" } }, + translate("Remote host name or ip address") }, { Flag, "remote_random", 0, @@ -863,7 +862,7 @@ for _, option in ipairs(params) do function o.remove(self, section) local cfg_val = AbstractValue.cfgvalue(self, section) local txt_val = luci.http.formvalue("cbid."..self.map.config.."."..section.."."..self.option..".textbox") - + if cfg_val and fs.access(cfg_val) and txt_val == "" then fs.unlink(cfg_val) end |