summaryrefslogtreecommitdiff
path: root/ale_linters/ruby/brakeman.vim
diff options
context:
space:
mode:
Diffstat (limited to 'ale_linters/ruby/brakeman.vim')
-rw-r--r--ale_linters/ruby/brakeman.vim7
1 files changed, 6 insertions, 1 deletions
diff --git a/ale_linters/ruby/brakeman.vim b/ale_linters/ruby/brakeman.vim
index 269c18f0..565c8c70 100644
--- a/ale_linters/ruby/brakeman.vim
+++ b/ale_linters/ruby/brakeman.vim
@@ -9,7 +9,12 @@ function! ale_linters#ruby#brakeman#Handle(buffer, lines) abort
return []
endif
- let l:result = json_decode(join(a:lines, ''))
+ try
+ let l:result = json_decode(join(a:lines, ''))
+ catch /E474/
+ " Ignore invalid JSON
+ return []
+ endtry
let l:output = []