remove garbage about unicode
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
This commit is contained in:
parent
d28ea704c4
commit
eab3e18613
@ -93,10 +93,6 @@ class CustomConfigParser(SafeConfigParser):
|
||||
def getlocaleval(self):
|
||||
xforms = [os.path.expanduser, os.path.expandvars]
|
||||
if self.has_option("general", "pythonfile"):
|
||||
if globals.options.use_unicode:
|
||||
path = uni.fsEncode(self.get("general", "pythonfile"),
|
||||
exception_msg="cannot convert character for pythonfile")
|
||||
else:
|
||||
path = self.get("general", "pythonfile")
|
||||
path = self.apply_xforms(path, xforms)
|
||||
else:
|
||||
@ -112,14 +108,6 @@ class CustomConfigParser(SafeConfigParser):
|
||||
For instance, for "Account Test", returns "Test"."""
|
||||
|
||||
key = key + ' '
|
||||
if globals.options.use_unicode:
|
||||
sections = []
|
||||
for section in self.sections():
|
||||
sections.append(uni.uni2str(section, exception_msg=
|
||||
"non ASCII character in section %s"% section))
|
||||
return [x[len(key):] for x in sections \
|
||||
if x.startswith(key)]
|
||||
else:
|
||||
return [x[len(key):] for x in self.sections() \
|
||||
if x.startswith(key)]
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user