fix(python): type error if conda-anaconda-home is unset

Amend: 8f60a1bc46
This commit is contained in:
Henrik Lissner 2024-09-09 14:39:44 -04:00
parent 632a091abb
commit 01c19094e8
No known key found for this signature in database
GPG key ID: B60957CA074D39A3

View file

@ -288,7 +288,7 @@
;; explicitly. Afterwards, run M-x `conda-env-activate' to switch between
;; environments
(or (cl-loop for dir in (cons conda-anaconda-home conda-home-candidates)
if (file-directory-p dir)
if (and dir (file-directory-p dir))
return (setq conda-anaconda-home (expand-file-name dir)
conda-env-home-directory (expand-file-name dir)))
(message "Cannot find Anaconda installation"))