From 5683ffe0d2436a7063b7f53f8a2cba14bce29602 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Sat, 8 Jun 2019 15:46:47 +0200 Subject: [PATCH] Fix +lookup/file in non-project files file-in-directory-p threw wrong-type-argument stringp errors because project-root was nil. --- modules/tools/lookup/autoload/lookup.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/tools/lookup/autoload/lookup.el b/modules/tools/lookup/autoload/lookup.el index 1ddb0028f..bcad68384 100644 --- a/modules/tools/lookup/autoload/lookup.el +++ b/modules/tools/lookup/autoload/lookup.el @@ -302,7 +302,7 @@ Otherwise, falls back on `find-file-at-point'." (ffap-file-finder (cond ((not (file-directory-p fullpath)) #'find-file) - ((file-in-directory-p fullpath project-root) + ((ignore-errors (file-in-directory-p fullpath project-root)) (lambda (dir) (let ((default-directory dir)) (without-project-cache!