Skip to content

Commit

Permalink
Fix return types of encoding utilities (#192)
Browse files Browse the repository at this point in the history
I discovered a badly annotated return types in encoding utilities.
  • Loading branch information
ziima authored Sep 13, 2023
1 parent d109f25 commit 5c138d3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions django-stubs/utils/encoding.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ class DjangoUnicodeDecodeError(UnicodeDecodeError):

def smart_text(
s: Any, encoding: str = ..., strings_only: bool = ..., errors: str = ...
) -> Any: ...
) -> str: ...
def is_protected_type(obj: Any) -> bool: ...
def force_text(
s: Any, encoding: str = ..., strings_only: bool = ..., errors: str = ...
) -> Any: ...
) -> str: ...
def force_bytes(
s: Any, encoding: str = ..., strings_only: bool = ..., errors: str = ...
) -> Any: ...
) -> bytes: ...

smart_str = smart_text
force_str = force_text
Expand Down

0 comments on commit 5c138d3

Please sign in to comment.