summaryrefslogtreecommitdiff
path: root/reconfigure/configs
diff options
context:
space:
mode:
authorAndrew Shadura <andrewsh@debian.org>2018-04-25 14:33:27 +0200
committerAndrew Shadura <andrewsh@debian.org>2018-04-25 14:34:10 +0200
commit14fd6b486cbbfbea4e4ee60f9f9a40e35ac9b3f2 (patch)
tree4f2f902bb837fedf04f6812ebaaf4a82b3bd3569 /reconfigure/configs
parent47946d0a8a68a8e260c9a44e8b2ab448b86f946e (diff)
parentb50a7a9f6a102709eacd1335c00a1e0d0b259b8e (diff)
Merge the new upstream version.
Diffstat (limited to 'reconfigure/configs')
-rw-r--r--reconfigure/configs/base.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/reconfigure/configs/base.py b/reconfigure/configs/base.py
index fc2ce6f..0d707fb 100644
--- a/reconfigure/configs/base.py
+++ b/reconfigure/configs/base.py
@@ -1,5 +1,4 @@
import chardet
-import six
import sys
@@ -38,8 +37,8 @@ class Reconfig (object):
self.content = open(self.origin, 'r').read()
self.encoding = 'utf8'
- if (six.PY3 and isinstance(self.content, bytes)) or \
- (six.PY2 and isinstance(self.content, str)):
+ if (sys.version_info[0] >= 3 and isinstance(self.content, bytes)) or \
+ (sys.version_info[0] == 2 and isinstance(self.content, str)):
try:
self.content = self.content.decode('utf8')
except (UnicodeDecodeError, AttributeError):