From e8e00799ac5068a15d50a980c38b96afdff2f996 Mon Sep 17 00:00:00 2001 From: John Bintz Date: Thu, 31 May 2012 11:05:39 -0400 Subject: [PATCH] safer way to access filetype --- plugin/taglist-plus.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugin/taglist-plus.vim b/plugin/taglist-plus.vim index cfaf879..67bde7b 100644 --- a/plugin/taglist-plus.vim +++ b/plugin/taglist-plus.vim @@ -960,7 +960,7 @@ endfunction " will be returned function! s:Tlist_Fix_Ftype(raw_ftype) if match(a:raw_ftype, '\.') - return split(a:raw_ftype, '\.')[0] + return get(split(a:raw_ftype, '\.'), 0, a:raw_ftype) else return a:raw_ftype endif