mirror of
https://github.com/gryf/tagbar.git
synced 2026-10-07 22:32:39 +02:00
Only determine extension once
This commit is contained in:
1 parent
f2c072dbb9
commit
bff765b957
1 file changed
+3
-2
+3
-2
@@ -1816,8 +1816,9 @@ function! s:ProcessFile(fname, ftype) abort
|
||||
endif
|
||||
|
||||
let tempfile = tempname()
|
||||
if fnamemodify(fileinfo.fpath, ':e') != ''
|
||||
let tempfile .= '.' . fnamemodify(fileinfo.fpath, ':e')
|
||||
let ext = fnamemodify(fileinfo.fpath, ':e')
|
||||
if ext != ''
|
||||
let tempfile .= '.' . ext
|
||||
endif
|
||||
|
||||
call writefile(getbufline(fileinfo.bufnr, 1, '$'), tempfile)
|
||||
|
||||
Reference in new issue
Block a user