Skip to content
Snippets Groups Projects
Commit 2540c906 authored by Junegunn Choi's avatar Junegunn Choi
Browse files

The last argument doesn't have to be a path

parent f2827410
No related branches found
No related tags found
No related merge requests found
......@@ -31,7 +31,7 @@ function! fzf#run(command, ...)
let cwd = getcwd()
try
let args = copy(a:000)
if len(args) > 0
if len(args) > 0 && isdirectory(expand(args[-1]))
let dir = remove(args, -1)
execute 'chdir '.s:escape(dir)
endif
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment