luci-app-ddns: fix handleReloadDDnsRule
authorAndy Chiang <redacted>
Thu, 28 May 2026 15:13:33 +0000 (22:13 +0700)
committerPaul Donald <redacted>
Thu, 28 May 2026 17:30:40 +0000 (20:30 +0300)
When DDNS is running, `dynamic_dns_lucihelper.sh` fails to reload.
It only starts when DDNS is stopped, which contradicts the button description.
Therefore, changed to `/etc/init.d/ddns restart section_id`.

Signed-off-by: Andy Chiang <redacted>
applications/luci-app-ddns/htdocs/luci-static/resources/view/ddns/overview.js

index 8578ce91efd0fed81677b5074bb6cf9d1ffa883f..0f46347adbe306c4d25d14430922f3bab1e21ed7 100644 (file)
@@ -164,8 +164,8 @@ return view.extend({
        },
 
        handleReloadDDnsRule(m, section_id, ev) {
-               return fs.exec('/usr/lib/ddns/dynamic_dns_lucihelper.sh',
-                                                       [ '-S', section_id, '--', 'start' ])
+               return fs.exec('/etc/init.d/ddns',
+                                                       [ 'restart', section_id ])
                        .then(L.bind(m.load, m))
                        .then(L.bind(m.render, m))
                        .catch(function(e) { ui.addNotification(null, E('p', e.message)) });
git clone https://git.99rst.org/PROJECT