about summary refs log tree commit diff
path: root/Completion/User/_perl_modules
diff options
context:
space:
mode:
Diffstat (limited to 'Completion/User/_perl_modules')
-rw-r--r--Completion/User/_perl_modules4
1 files changed, 2 insertions, 2 deletions
diff --git a/Completion/User/_perl_modules b/Completion/User/_perl_modules
index c6ea93f4c..d63f94f1b 100644
--- a/Completion/User/_perl_modules
+++ b/Completion/User/_perl_modules
@@ -22,11 +22,11 @@ zparseopts -D -a opts S: q
 
 if [[ ${+_perl_modules} -eq 0 ]]; then
   if zstyle -t ":completion:${curcontext}:modules" try-to-use-pminst \
-     && which pminst >/dev/null; then
+     && (( ${+commands[pminst]} )); then
     _perl_modules=( $(pminst) )
   else
     local inc libdir new_pms
-    if which perl >/dev/null; then
+    if (( ${+commands[perl]} )); then
       inc=( $( perl -e 'print "@INC"' ) )
     else
       # If perl isn't there, one wonders why the user's trying to