Skip to content

Commit 54d5ddd

Browse files
author
Luca Moschella
committed
Remove Union[str, Path] typing in favor of str
1 parent d11846f commit 54d5ddd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

fsspec/implementations/prefix.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def _get_relative_path(self, path: str) -> str:
2929
return path[len(self.sep) :]
3030
return path
3131

32-
def _add_fs_prefix(self, path: Union[str, Path]) -> Union[str, Sequence[str]]:
32+
def _add_fs_prefix(self, path: str) -> Union[str, Sequence[str]]:
3333
if isinstance(path, (str, Path)):
3434
path = stringify_path(path)
3535
protocol, path = split_protocol(path)
@@ -46,7 +46,7 @@ def _add_fs_prefix(self, path: Union[str, Path]) -> Union[str, Sequence[str]]:
4646
return [self._add_fs_prefix(x) for x in path]
4747
assert False
4848

49-
def _remove_fs_prefix(self, path: Union[str, Path]) -> Union[str, Sequence[str]]:
49+
def _remove_fs_prefix(self, path: str) -> Union[str, Sequence[str]]:
5050
if isinstance(path, (str, Path)):
5151
path = stringify_path(path)
5252
protocol, path = split_protocol(path)

0 commit comments

Comments
 (0)