Skip to content

Commit f34e492

Browse files
committed
Merge branch 'directory' into compress
2 parents 0e60d49 + 740e8ac commit f34e492

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pyiron_snippets/files.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ def categorize_folder_items(folder_path):
4242

4343

4444
class DirectoryObject:
45-
def __init__(self, directory: str | Path | DirectoryObject):
45+
def __init__(self, directory: str | Path | DirectoryObject, protected: bool = False):
4646
if isinstance(directory, str):
4747
path = Path(directory)
4848
elif isinstance(directory, Path):
@@ -51,7 +51,7 @@ def __init__(self, directory: str | Path | DirectoryObject):
5151
path = directory.path
5252
self.path: Path = path
5353
self.create()
54-
self._protected = False
54+
self._protected = protected
5555

5656
def __getstate__(self):
5757
self._protected = True

0 commit comments

Comments
 (0)