Skip to content

Commit

Permalink
should be convert from utf-8
Browse files Browse the repository at this point in the history
  • Loading branch information
mattn committed Feb 21, 2013
1 parent 84b173f commit 45139de
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion autoload/webapi/json.vim
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ function! webapi#json#decode(json)
let json = substitute(json, '\n', '', 'g')
let json = substitute(json, '\\u34;', '\\"', 'g')
if v:version >= 703 && has('patch780')
let json = substitute(json, '\\u\(\x\x\x\x\)', '\=nr2char(str2nr(submatch(1), 16), 1)', 'g')
let json = substitute(json, '\\u\(\x\x\x\x\)', '\=iconv(nr2char(str2nr(submatch(1), 16), 1), "utf-8", &encoding)', 'g')
else
let json = substitute(json, '\\u\(\x\x\x\x\)', '\=s:nr2enc_char("0x".submatch(1))', 'g')
endif
Expand Down

0 comments on commit 45139de

Please sign in to comment.