branch: elpa/projectile
commit fd3b64146e581ad10c383bb7335407188184b07b
Author: Bozhidar Batsov <[email protected]>
Commit: Bozhidar Batsov <[email protected]>
Use string-search instead of string-match in projectile-select-files
The filename text at point (from thing-at-point or region) was used
directly as a regexp pattern in string-match. Characters like [ ] ( )
would cause invalid-regexp errors or incorrect matches. Use
string-search for literal substring matching instead.
---
projectile.el | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/projectile.el b/projectile.el
index 6c833af4b7..be6dd1630d 100644
--- a/projectile.el
+++ b/projectile.el
@@ -2503,7 +2503,7 @@ With a prefix arg INVALIDATE-CACHE invalidates the cache
first."
(files (if file
(seq-filter
(lambda (project-file)
- (string-match file project-file))
+ (string-search file project-file))
project-files)
nil)))
files))