summaryrefslogtreecommitdiff
path: root/plugin/ale.vim
diff options
context:
space:
mode:
Diffstat (limited to 'plugin/ale.vim')
-rw-r--r--plugin/ale.vim4
1 files changed, 3 insertions, 1 deletions
diff --git a/plugin/ale.vim b/plugin/ale.vim
index bdbf3ad1..8fa0093c 100644
--- a/plugin/ale.vim
+++ b/plugin/ale.vim
@@ -194,7 +194,9 @@ function! s:ALEToggle() abort
" Lint immediately
call ale#Queue(0)
else
- for l:buffer in keys(g:ale_buffer_info)
+ " Make sure the buffer number is a number, not a string,
+ " otherwise things can go wrong.
+ for l:buffer in map(keys(g:ale_buffer_info), 'str2nr(v:val)')
" Stop jobs and delete stored buffer data
call ale#cleanup#Buffer(l:buffer)
" Clear signs, loclist, quicklist