diff --git a/scripts/checkUpdates.sh b/scripts/checkUpdates.sh index cff43db..c13d081 100755 --- a/scripts/checkUpdates.sh +++ b/scripts/checkUpdates.sh @@ -13,9 +13,13 @@ has_param() { wait_for_process_to_finish() { local process_name="$1" - while pgrep -a "$process_name" >/dev/null; do - sleep 0.1 + local pid + + while pid=$(pgrep -x "$process_name"); do + wait "$pid" 2>/dev/null || true done + + sleep 2 } check_arch_updates() { diff --git a/src/components/bar/modules/updates/index.tsx b/src/components/bar/modules/updates/index.tsx index a367150..cb0cb0f 100644 --- a/src/components/bar/modules/updates/index.tsx +++ b/src/components/bar/modules/updates/index.tsx @@ -34,7 +34,7 @@ const processUpdateCount = (updateCount: string): string => { const processUpdateTooltip = (updateTooltip: string, updateCount: Variable): string => { const defaultTooltip = updateCount.get() + ' updates available'; - if (!extendedTooltip.get()) return defaultTooltip; + if (!extendedTooltip.get() || !updateTooltip) return defaultTooltip; return defaultTooltip + '\n\n' + updateTooltip; };