From 501640081f58deec167cc44251e14e78ace710bb Mon Sep 17 00:00:00 2001 From: =?utf8?q?Rafa=C5=82=20Mi=C5=82ecki?= Date: Fri, 27 Jun 2014 19:38:35 +0000 Subject: [PATCH] luci2: UCIContext: add: respect "name" if passed MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit This allows creating UCI entries with a desired name, e.g. config interface 'guestlan' Signed-off-by: Rafał Miłecki --- luci2/htdocs/luci2/luci2.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/luci2/htdocs/luci2/luci2.js b/luci2/htdocs/luci2/luci2.js index 2a2a359..040f1e5 100644 --- a/luci2/htdocs/luci2/luci2.js +++ b/luci2/htdocs/luci2/luci2.js @@ -974,7 +974,7 @@ function LuCI2() add: function(conf, type, name) { var n = this.state.creates; - var sid = this.createSID(conf); + var sid = name || this.createSID(conf); if (!n[conf]) n[conf] = { }; -- 2.30.2