Skip to content

Commit 5805b2c

Browse files
authored
as_filesytem: properly work for LocalFileSystem (#86)
1 parent 2d72c4d commit 5805b2c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/dvc_objects/fs/__init__.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,8 @@ def as_filesystem(
8484
return fs
8585

8686
protos = (fs.protocol,) if isinstance(fs.protocol, str) else fs.protocol
87-
if "file" in protos:
88-
protos = ("local", *protos)
87+
if "file" in protos or "local" in protos:
88+
return LocalFileSystem()
8989

9090
# if we have the class in our registry, instantiate with that.
9191
for proto in protos:

0 commit comments

Comments
 (0)