luci-app-ddns: fix creation of custom service (fix #4926)
The `service_name` option must be empty for custom services, otherwise an error is raised in `dynamic_dns_updater.sh`. Signed-off-by: Julien Cassette <julien.cassette@gmail.com>
This commit is contained in:
parent
0c5d7dd8d7
commit
85ff9db2bf
1 changed files with 3 additions and 1 deletions
|
@ -477,7 +477,9 @@ return view.extend({
|
|||
|
||||
return m.save(function() {
|
||||
uci.add('ddns', 'service', section_id);
|
||||
uci.set('ddns', section_id, 'service_name', service_value);
|
||||
if (service_value != '-') {
|
||||
uci.set('ddns', section_id, 'service_name', service_value);
|
||||
}
|
||||
uci.set('ddns', section_id, 'use_ipv6', ipv6_value);
|
||||
}).then(L.bind(m.children[1].renderMoreOptionsModal, m.children[1], section_id));
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue