Skip to content

Commit

Permalink
api: fix bug in refresh_all_pkgapp_status
Browse files Browse the repository at this point in the history
introduced in Botspot@ae99e1b

the change from `arch` to `dpkg_arch` was a last minute change and one location was missed
  • Loading branch information
theofficialgman committed Mar 11, 2024
1 parent b83baff commit 90d1cef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api
Original file line number Diff line number Diff line change
Expand Up @@ -1847,7 +1847,7 @@ refresh_all_pkgapp_status() { #for every package-app, if dpkg thinks it's instal
local apt_cache_output="$(echo "$packages" | xargs -r apt-cache policy)"

#redefine package_installed to only read /var/lib/dpkg/status once
local dpkg_status="$(grep -x "Package: \($(echo "$packages" | sed 's/:'"$arch"'//g ; s/ /\\|/g')\)" -A 2 /var/lib/dpkg/status)"
local dpkg_status="$(grep -x "Package: \($(echo "$packages" | sed 's/:'"$dpkg_arch"'//g ; s/ /\\|/g')\)" -A 2 /var/lib/dpkg/status)"

#redefine package_available() to use apt_cache_output and avoid running apt-cache multiple times
(package_available() { #this will only be used in this function's subprocesses.
Expand Down

0 comments on commit 90d1cef

Please sign in to comment.