Some code cosmetics

This commit is contained in:
Ozzie Isaacs
2021-03-14 15:06:09 +01:00
parent 4df443e007
commit 8c751eb532
8 changed files with 57 additions and 54 deletions
+2 -1
View File
@@ -267,7 +267,8 @@ class Updater(threading.Thread):
log.debug("Could not remove: %s", item_path)
shutil.rmtree(source, ignore_errors=True)
def is_venv(self):
@staticmethod
def is_venv():
if (hasattr(sys, 'real_prefix')) or (hasattr(sys, 'base_prefix') and sys.base_prefix != sys.prefix):
return os.sep + os.path.relpath(sys.prefix, constants.BASE_DIR)
else: