Skip to content

Commit

Permalink
Fix lambda in map() (#246)
Browse files Browse the repository at this point in the history
Close #244
  • Loading branch information
liuchengxu authored Sep 14, 2023
1 parent 0b901c9 commit 08cf520
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions autoload/which_key/char_handler.vim
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ function! s:initialize_exit_code() abort
elseif ty == s:TYPE.string
let s:exit_code = [g:which_key_exit]
elseif ty == s:TYPE.list
let s:exit_code = map(g:which_key_exit, {e ->
\ type(e) == s:TYPE.number ? nr2char(e) : e})
let s:exit_code = map(g:which_key_exit, {_, val ->
\ type(val) == s:TYPE.number ? nr2char(val) : val})
else
echohl ErrorMsg
echon '[which-key] '.g:which_key_exit.' is invalid for option g:which_key_exit'
Expand Down

0 comments on commit 08cf520

Please sign in to comment.