Skip to content
This repository has been archived by the owner on Mar 13, 2023. It is now read-only.

Commit

Permalink
support chn menu on windows simplified cdn locale
Browse files Browse the repository at this point in the history
  • Loading branch information
fffonion committed Sep 2, 2017
1 parent 02083c8 commit 9a2b244
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cloudflare-partner-cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,10 @@
}

def i18n(s):
return I18N[s] if LOCALE[1] and LOCALE[1].lower() == "utf-8" and s in I18N else s
_ = I18N[s] if LOCALE[1] and LOCALE[1].lower() in ("utf-8", "cp936") and s in I18N else s
if LOCALE[1].lower() == "cp936" and not PY3K: # windows with simplified Chinese locale
return _.decode('utf-8').encode('gb18030')
return _

def log(fmt, arg = (), level = "INFO"):
if PY3K:
Expand Down

0 comments on commit 9a2b244

Please sign in to comment.