From c636bf374f2bafe044ee56ad170a186cf2bbb6e5 Mon Sep 17 00:00:00 2001
From: "Alexey I. Froloff" <raorn@raorn.name>
Date: Thu, 7 Feb 2019 15:22:56 +0300
Subject: [PATCH] net/acme: commit uhttpd configuration if update_httpd set

uhttpd configuration should be commited when update_uhttpd set.

Signed-off-by: Alexey I. Froloff <raorn@raorn.name>
---
 net/acme/files/run.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/acme/files/run.sh b/net/acme/files/run.sh
index 144cdcd09..b5dfc731d 100644
--- a/net/acme/files/run.sh
+++ b/net/acme/files/run.sh
@@ -132,9 +132,9 @@ post_checks()
     if [ -e /etc/init.d/uhttpd ] && ( [ -n "$UHTTPD_LISTEN_HTTP" ] || [ $UPDATE_UHTTPD -eq 1 ] ); then
         if [ -n "$UHTTPD_LISTEN_HTTP" ]; then
             uci set uhttpd.main.listen_http="$UHTTPD_LISTEN_HTTP"
-            uci commit uhttpd
             UHTTPD_LISTEN_HTTP=
         fi
+        uci commit uhttpd
         /etc/init.d/uhttpd reload
     fi