Skip to content

Commit

Permalink
[Units] Add type hints for WikiArticle.__eq__
Browse files Browse the repository at this point in the history
  • Loading branch information
Harmon758 committed Jul 30, 2023
1 parent 7465798 commit f1cd951
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion units/wikis.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
if TYPE_CHECKING:
import aiohttp
from collections.abc import Iterable
from types import NotImplementedType


class WikiInfo(BaseModel):
Expand All @@ -28,7 +29,7 @@ class WikiArticle(BaseModel):
image_url: str | None
wiki: WikiInfo

def __eq__(self, other):
def __eq__(self, other: object) -> bool | NotImplementedType:
if isinstance(other, WikiArticle):
return self.url == other.url
else:
Expand Down

0 comments on commit f1cd951

Please sign in to comment.