mirror of
https://github.com/Telecominfraproject/wlan-ap.git
synced 2025-10-29 17:42:41 +00:00
firstcontact: support server:port syntax inside redirector field
Signed-off-by: John Crispin <john@phrozen.org>
This commit is contained in:
@@ -43,8 +43,11 @@ if (!config.Redirector) {
|
||||
|
||||
function store_config(path) {
|
||||
let cursor = uci.cursor(path);
|
||||
let redir = split(config.Redirector, ":");
|
||||
|
||||
cursor.load("ucentral");
|
||||
cursor.set("ucentral", "config", "server", config.Redirector);
|
||||
cursor.set("ucentral", "config", "server", redir[0]);
|
||||
cursor.set("ucentral", "config", "port", redir[1] || 15002);
|
||||
cursor.commit();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user