From d60719ac3bf4ed1b10779406fd656e37c0bc42a3 Mon Sep 17 00:00:00 2001 From: mitermayer Date: Wed, 24 May 2017 16:10:44 -0700 Subject: Removing already actioned TODO and fixing indentation --- autoload/prettier.vim | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'autoload/prettier.vim') diff --git a/autoload/prettier.vim b/autoload/prettier.vim index 3cb21ee..3ec6cfb 100644 --- a/autoload/prettier.vim +++ b/autoload/prettier.vim @@ -1,6 +1,5 @@ let s:root_dir = fnamemodify(resolve(expand(':p')), ':h') -" TODO => check all &ft comparisons and make sure we use match to protect from compound file types function! prettier#Prettier() abort let l:exec = s:Get_Prettier_Exec() @@ -11,11 +10,11 @@ function! prettier#Prettier() abort if exec != -1 let l:stdout = split(system(exec . s:Get_Prettier_Exec_Args(), getbufline(bufnr('%'), 1, '$')), '\n') - " delete all lines on the current buffer - silent! execute 1 . ',' . line('$') . 'delete _' + " delete all lines on the current buffer + silent! execute 1 . ',' . line('$') . 'delete _' - " replace all lines from the current buffer with output from prettier - call setline(1, stdout) + " replace all lines from the current buffer with output from prettier + call setline(1, stdout) else call s:Suggest_Install_Prettier() endif -- cgit v1.3