Skip to content

Commit 185204a

Browse files
committed
fix(mimetypes): update MimeTypes.read to accept Paths
1 parent 8b3caac commit 185204a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

stdlib/mimetypes.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ class MimeTypes:
4949
def guess_extension(self, type: str, strict: bool = True) -> str | None: ...
5050
def guess_type(self, url: StrPath, strict: bool = True) -> tuple[str | None, str | None]: ...
5151
def guess_all_extensions(self, type: str, strict: bool = True) -> list[str]: ...
52-
def read(self, filename: str, strict: bool = True) -> None: ...
52+
def read(self, filename: StrPath, strict: bool = True) -> None: ...
5353
def readfp(self, fp: IO[str], strict: bool = True) -> None: ...
5454
def read_windows_registry(self, strict: bool = True) -> None: ...
5555
if sys.version_info >= (3, 13):

0 commit comments

Comments
 (0)