Skip to content

Commit 8274975

Browse files
committed
Linting.
1 parent 8c98268 commit 8274975

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

domdf_python_tools/words.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -600,7 +600,7 @@ class Plural(functools.partial):
600600
def __init__(self, singular: str, plural: str):
601601
pass
602602

603-
def __call__(self, n: int) -> str:
603+
def __call__(self, n: int) -> str: # type: ignore
604604
"""
605605
Returns either the singular or plural form of the word depending on the value of ``n``.
606606
@@ -613,13 +613,13 @@ def __init__(self, singular: str, plural: str):
613613
super().__init__(ngettext, singular, plural)
614614
else:
615615

616-
def __new__(cls, singular: str, plural: str):
617-
return super().__new__(cls, ngettext, singular, plural)
616+
def __new__(cls, singular: str, plural: str): # noqa: D102
617+
return functools.partial.__new__(cls, ngettext, singular, plural) # type: ignore
618618

619619
@recursive_repr()
620620
def __repr__(self):
621621
qualname = type(self).__qualname__
622-
args = []
622+
args: List[str] = []
623623
args.extend(repr(x) for x in self.args)
624624
args.extend(f"{k}={v!r}" for (k, v) in self.keywords.items())
625625
return f"{qualname}({', '.join(args)})"

0 commit comments

Comments
 (0)