Skip to content

Commit 7ac1527

Browse files
committed
refactor(_comp_finalize): use a simple prefix for local variables
1 parent 56f5510 commit 7ac1527

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

bash_completion

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -920,16 +920,16 @@ _comp_finalize()
920920
while ((${#FUNCNAME[@]} <= ${_comp_finalize__depth[-1]})); do
921921
if [[ ${#FUNCNAME[@]} -eq ${_comp_finalize__depth[-1]} && ${FUNCNAME[1]-} == "${_comp_finalize__target[-1]}" ]]; then
922922
# Call finalizer for each command
923-
local cmd=${words[0]-} _comp_local_hook
923+
local cmd=${words[0]-} _hook
924924
if [[ $cmd ]]; then
925-
_comp_local_hook=${BASH_COMPLETION_FINALIZE_CMD_HOOKS[$cmd]-}
926-
eval -- "$_comp_local_hook"
925+
_hook=${BASH_COMPLETION_FINALIZE_CMD_HOOKS[$cmd]-}
926+
eval -- "$_hook"
927927
fi
928928

929929
# Call general finalizers
930930
if [[ ${BASH_COMPLETION_FINALIZE_HOOKS[*]+set} ]]; then
931-
for _comp_local_hook in "${BASH_COMPLETION_FINALIZE_HOOKS[@]}"; do
932-
eval -- "$_comp_local_hook"
931+
for _hook in "${BASH_COMPLETION_FINALIZE_HOOKS[@]}"; do
932+
eval -- "$_hook"
933933
done
934934
fi
935935
fi

0 commit comments

Comments
 (0)