summaryrefslogtreecommitdiff
path: root/kvmd/helpers
diff options
context:
space:
mode:
authorMaxim Devaev <[email protected]>2022-04-10 06:14:48 +0300
committerMaxim Devaev <[email protected]>2022-04-10 06:14:48 +0300
commitc92d17dea21fbcf461716331ea7fd3500476edb9 (patch)
tree0d170fcf38d71a4762e8be15784c56fc23017d9e /kvmd/helpers
parent486f1be9867fcb3220a2918ddd5b0371ece17d5d (diff)
refactoring
Diffstat (limited to 'kvmd/helpers')
-rw-r--r--kvmd/helpers/remount/__init__.py13
1 files changed, 6 insertions, 7 deletions
diff --git a/kvmd/helpers/remount/__init__.py b/kvmd/helpers/remount/__init__.py
index 28872206..960339f3 100644
--- a/kvmd/helpers/remount/__init__.py
+++ b/kvmd/helpers/remount/__init__.py
@@ -113,10 +113,9 @@ def main() -> None:
storage = _find_storage(target)
_remount(storage.mount_path, rw)
- if rw:
- if storage.root_path:
- for name in dirs:
- path = os.path.join(storage.root_path, name)
- _mkdir(path)
- if storage.user:
- _chown(path, storage.user)
+ if rw and storage.root_path:
+ for name in dirs:
+ path = os.path.join(storage.root_path, name)
+ _mkdir(path)
+ if storage.user:
+ _chown(path, storage.user)