From: Jo-Philipp Wich Date: Sat, 20 Mar 2021 16:15:48 +0000 (+0100) Subject: luci-app-opkg: fix parsing empty package repository indexes X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=3bcbcbf0889142ca19b893f41318963b69de90ab;p=project%2Fluci.git luci-app-opkg: fix parsing empty package repository indexes Signed-off-by: Jo-Philipp Wich --- diff --git a/applications/luci-app-opkg/htdocs/luci-static/resources/view/opkg.js b/applications/luci-app-opkg/htdocs/luci-static/resources/view/opkg.js index be1bd944e6..fe5600e880 100644 --- a/applications/luci-app-opkg/htdocs/luci-static/resources/view/opkg.js +++ b/applications/luci-app-opkg/htdocs/luci-static/resources/view/opkg.js @@ -181,7 +181,7 @@ function parseList(s, dest) key = RegExp.$1.toLowerCase(); val = RegExp.$2.trim(); } - else { + else if (pkg) { dest.pkgs[pkg.name] = pkg; var provides = dest.providers[pkg.name] ? [] : [ pkg.name ];