From: Jo-Philipp Wich Date: Sat, 22 Feb 2020 21:19:54 +0000 (+0100) Subject: luci-app-firewall: snats.js: fix rewrite IP validation for SNAT target X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=d527c28ffa973e04f1ed3eac9f4a7504404b4fcd;p=oweals%2Fluci.git luci-app-firewall: snats.js: fix rewrite IP validation for SNAT target Signed-off-by: Jo-Philipp Wich --- diff --git a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/snats.js b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/snats.js index 9efa1a749..8a1d41e71 100644 --- a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/snats.js +++ b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/snats.js @@ -220,7 +220,7 @@ return L.view.extend({ a = this.formvalue(section_id), p = port ? port[0].formvalue(section_id) : null; - if ((a == null || a == '') && (p == null || p == '')) + if ((a == null || a == '') && (p == null || p == '') && value == '') return _('A rewrite IP must be specified!'); return true;