diff --git a/lib/git/repo_index.sh b/lib/git/repo_index.sh index 30c24c1..8cf744b 100644 --- a/lib/git/repo_index.sh +++ b/lib/git/repo_index.sh @@ -225,7 +225,7 @@ _git_index_update_all_branches() { local index=0 # Iterate over branches, and update those that can be fast-forwarded - for branch in $branches; do + for branch in ${branches[@]}; do branch_rev="$(git rev-parse $branch)" # Local branch can be fast-forwarded if revision is ancestor of remote revision, and not the same. # (see http://stackoverflow.com/a/2934062/304706)