Cancel goto() if input was empty

This commit is contained in:
R. David Dunphy
2023-04-02 00:57:52 +01:00
parent dec6a9ecab
commit 8f651834fd
+5
View File
@@ -495,6 +495,11 @@ function! vimwiki#base#goto(...) abort
let key = a:0 > 0 && a:1 !=# '' ? a:1 : input('Enter name: ', '',
\ 'customlist,vimwiki#base#complete_links_escaped')
if key ==# ''
" Input cancelled
return
endif
let anchor = a:0 > 1 ? a:2 : ''
" Save current file pos