diff options
author | Shougo Matsushita <Shougo.Matsu@gmail.com> | 2018-10-14 17:23:31 +0900 |
---|---|---|
committer | Shougo Matsushita <Shougo.Matsu@gmail.com> | 2018-11-08 21:34:17 +0900 |
commit | 51f679d977456fad0c65f1ff1b1cbee44894b1f1 (patch) | |
tree | 5e2bb5b854932648e80e932b6d71ccea0abc4a45 /autoload/deoplete/init.vim | |
parent | db2fbd1ea6a249672edcd9da8caae3e5e1851c59 (diff) | |
download | deoplete.nvim-51f679d977456fad0c65f1ff1b1cbee44894b1f1.zip |
Improve context initialization
Diffstat (limited to 'autoload/deoplete/init.vim')
-rw-r--r-- | autoload/deoplete/init.vim | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/autoload/deoplete/init.vim b/autoload/deoplete/init.vim index ea1db3a..d859e55 100644 --- a/autoload/deoplete/init.vim +++ b/autoload/deoplete/init.vim @@ -218,13 +218,6 @@ function! deoplete#init#_context(event, sources) abort let [filetype, filetypes, same_filetypes] = \ deoplete#util#get_context_filetype(input, a:event) - let sources = deoplete#util#convert2list(a:sources) - if a:event !=# 'Manual' && empty(sources) - " Use default sources - let sources = deoplete#custom#_get_filetype_option( - \ 'sources', filetype, []) - endif - let event = (deoplete#util#get_prev_event() ==# 'Refresh') ? \ 'Manual' : a:event @@ -240,7 +233,8 @@ function! deoplete#init#_context(event, sources) abort \ 'filetype': filetype, \ 'filetypes': filetypes, \ 'same_filetypes': same_filetypes, - \ 'sources': sources, + \ 'sources': deoplete#custom#_get_filetype_option( + \ 'sources', filetype, []), \ 'max_abbr_width': max_width, \ 'max_kind_width': max_width, \ 'max_menu_width': max_width, |