diff --git a/lib/utilities.bash b/lib/utilities.bash index 4bf26f10ae..a727cfb56e 100644 --- a/lib/utilities.bash +++ b/lib/utilities.bash @@ -84,9 +84,10 @@ function _bash-it-component-help() cat "${file}" } -_bash-it-component-cache-file() { - local component="$(_bash-it-pluralize-component "${1}")" - local file="${BASH_IT}/tmp/cache/${component}" +function _bash-it-component-cache-file() { + local component file + component="$(_bash-it-pluralize-component "${1}")" + file="${BASH_IT}/tmp/cache/${component}" [[ -f "${file}" ]] || mkdir -p "${file%/*}" printf '%s' "${file}" }