adblock: fix when PROCD_RELOAD_DELAY is set 14320/head
authorThiago de Arruda Padilha <tpadilha84@gmail.com>
Wed, 23 Dec 2020 18:17:17 +0000 (15:17 -0300)
committerThiago de Arruda Padilha <tpadilha84@gmail.com>
Wed, 23 Dec 2020 19:59:32 +0000 (16:59 -0300)
Move the "PROCD_RELOAD_DELAY" line to after the "delay" variable is set.

Signed-off-by: Thiago de Arruda Padilha <tpadilha84@gmail.com>
net/adblock/Makefile
net/adblock/files/adblock.init

index f25ac574970edebd3233e5d1efbc2c7f26024420..81be42b7e8ac5b068f1738615bd5994682dadc35 100644 (file)
@@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=adblock
 PKG_VERSION:=4.0.8
-PKG_RELEASE:=2
+PKG_RELEASE:=3
 PKG_LICENSE:=GPL-3.0-or-later
 PKG_MAINTAINER:=Dirk Brenken <dev@brenken.org>
 
index c75ddee67319c0651d43968d23f208b0fab142d8..0aa219d449efba3fb7d72ce041732400fa08892d 100755 (executable)
@@ -246,10 +246,10 @@ service_triggers()
 {
        local trigger delay type
 
-       PROCD_RELOAD_DELAY=$((delay*1000))
        trigger="$(uci_get adblock global adb_trigger)"
        delay="$(uci_get adblock global adb_triggerdelay "2")"
        type="$(uci_get adblock global adb_starttype "start")"
+       PROCD_RELOAD_DELAY=$((delay*1000))
        if [ -n "${trigger}" ]
        then
                procd_add_interface_trigger "interface.*.up" "${trigger}" "${adb_init}" "${type}"