From 0049934875f9cc4a7a40482767d3afb64bc5df8a Mon Sep 17 00:00:00 2001 From: Dave Reisner Date: Tue, 5 Aug 2014 08:31:42 -0400 Subject: cache even empty replies from the remote --- remote.inc.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/remote.inc.sh b/remote.inc.sh index 1554d3a..4e31696 100644 --- a/remote.inc.sh +++ b/remote.inc.sh @@ -3,7 +3,7 @@ declare -A refcache=() remote_get_all_refs() { local remote=$1 - if [[ -z ${refcache["$remote"]} ]]; then + if [[ -z ${refcache["$remote"]+cached} ]]; then refcache["$remote"]=$(git ls-remote "$remote" 'refs/heads/packages/*' | awk '{ sub(/refs\/heads\//, "", $2); print $2 }') fi -- cgit v1.2.3-70-g09d2