Refactor: More descriptive method name

This commit is contained in:
JarrodCTaylor 2015-11-14 16:52:55 -06:00
parent 1d4d8b0490
commit 53571bf4f5

View File

@ -31,7 +31,7 @@ function! s:unite_source.action_table.expand.func(candidate)
return '' return ''
endfunction endfunction
function! s:unite_source.longest_snippet(snippet_list) function! s:unite_source.get_longest_snippet_len(snippet_list)
let longest = 0 let longest = 0
for snip in items(a:snippet_list) for snip in items(a:snippet_list)
if strlen(snip['word']) > longest if strlen(snip['word']) > longest
@ -46,7 +46,7 @@ function! s:unite_source.gather_candidates(args, context)
\ 'ultisnips', 'unite__is_marked': 0, 'kind': 'command', 'is_matched': 1, \ 'ultisnips', 'unite__is_marked': 0, 'kind': 'command', 'is_matched': 1,
\ 'is_multiline': 0} \ 'is_multiline': 0}
let snippet_list = UltiSnips#SnippetsInCurrentScope() let snippet_list = UltiSnips#SnippetsInCurrentScope()
let max_len = s:unite_source.longest_snippet(snippet_list) let max_len = s:unite_source.get_longest_snippet_len(snippet_list)
let canditates = [] let canditates = []
for snip in items(snippet_list) for snip in items(snippet_list)
let curr_val = copy(default_val) let curr_val = copy(default_val)