From 623099d837ebdf37c6a46359c46af872b9feab01 Mon Sep 17 00:00:00 2001 From: nftbty Date: Fri, 24 Mar 2023 13:39:31 +0800 Subject: [PATCH] luci: app_update use default_path when not set in config --- luci-app-passwall/luasrc/passwall/api.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/luci-app-passwall/luasrc/passwall/api.lua b/luci-app-passwall/luasrc/passwall/api.lua index 76c832111..ad51f5597 100644 --- a/luci-app-passwall/luasrc/passwall/api.lua +++ b/luci-app-passwall/luasrc/passwall/api.lua @@ -413,7 +413,9 @@ local function get_bin_version_cache(file, cmd) end function get_app_path(app_name) + local def_path = com[app_name].default_path local path = uci_get_type("global_app", app_name:gsub("%-","_") .. "_file") + path = path and (#path>0 and path or def_path) or def_path return path end