Better way to strip pyc/pyd from config file path

This commit is contained in:
shortcutme 2017-07-12 12:28:21 +02:00
parent 2777c4c537
commit 3cd7e4e48e
No known key found for this signature in database
GPG key ID: 5B63BAE6CB9613AE

View file

@ -61,7 +61,7 @@ class Config(object):
else: else:
fix_float_decimals = False fix_float_decimals = False
this_file = os.path.abspath(__file__).replace("\\", "/").replace("Config.pyc", "Config.py") this_file = os.path.abspath(__file__).replace("\\", "/").rstrip("cd")
if this_file.endswith("/Contents/Resources/core/src/Config.py"): if this_file.endswith("/Contents/Resources/core/src/Config.py"):
# Running as ZeroNet.app # Running as ZeroNet.app