From dd8b39a9b56ff776311d465d8ebc081e52ee2cc1 Mon Sep 17 00:00:00 2001 From: Michael Sanders Date: Sun, 1 Mar 2009 17:24:38 -0500 Subject: [PATCH] fixed typo in check for file-based snippets --- after/plugin/snipMate.vim | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/after/plugin/snipMate.vim b/after/plugin/snipMate.vim index 2512c75..3363209 100644 --- a/after/plugin/snipMate.vim +++ b/after/plugin/snipMate.vim @@ -19,16 +19,16 @@ if !exists('snippets_dir') let snippets_dir = $HOME.(has('win16') || has('win32') || has('win64') ? \ '\vimfiles\snippets' : '/.vim/snippets/') endif -if isdirectory(snippets_dir) - if isdirectory(snippets_dir.'_') - call ExtractSnips(snippets_dir.'_', '_') - endif - au FileType * cal s:GetSnippets() - fun s:GetSnippets() - for ft in split(&ft, '\.') - if !exists('did_ft_'.&ft) && isdirectory(snippets_dir.ft) - cal ExtractSnips(snippets_dir.ft, ft) - endif - endfor - endf +if !isdirectory(snippets_dir) | finish | endif + +if isdirectory(snippets_dir.'_') + call ExtractSnips(snippets_dir.'_', '_') endif +au FileType * call s:GetSnippets() +fun s:GetSnippets() + for ft in split(&ft, '\.') + if !exists('g:did_ft_'.ft) && isdirectory(g:snippets_dir.ft) + call ExtractSnips(g:snippets_dir.ft, ft) + endif + endfor +endf