branch: externals/ivy-hydra
commit 05c12fcc5affc0febe17e2aba8b6813eb567f1cf
Author: Mario Rodas <[email protected]>
Commit: Oleh Krehel <[email protected]>

    counsel.el (counsel--grep-smart-case-flag): Check if base command is a 
string
    
    Fixes #2579
---
 counsel.el | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/counsel.el b/counsel.el
index 820f76c..10301f2 100644
--- a/counsel.el
+++ b/counsel.el
@@ -3035,7 +3035,8 @@ Works for `counsel-git-grep', `counsel-ag', etc."
 (defun counsel--grep-smart-case-flag ()
   (if (ivy--case-fold-p ivy-text)
       "-i"
-    (if (string-match-p "\\`pt" counsel-ag-base-command)
+    (if (and (stringp counsel-ag-base-command)
+             (string-match-p "\\`pt" counsel-ag-base-command))
         "-S"
       "-s")))
 

Reply via email to