Skip to content

Commit

Permalink
Merge pull request #234 from cthoyt/patch-1
Browse files Browse the repository at this point in the history
Fix hard-coded class reference in fromkeys()
  • Loading branch information
corenting committed Jul 3, 2023
2 parents 6d8b83e + 2e058d6 commit f803ec3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion immutabledict/__init__.py
Expand Up @@ -23,7 +23,7 @@ class immutabledict(Mapping[_K, _V]):
def fromkeys(
cls, seq: Iterable[_K], value: Optional[_V] = None
) -> "immutabledict[_K, _V]":
return cls(dict.fromkeys(seq, value))
return cls(cls.dict_cls.fromkeys(seq, value))

def __init__(self, *args: Any, **kwargs: Any) -> None:
self._dict = self.dict_cls(*args, **kwargs)
Expand Down

0 comments on commit f803ec3

Please sign in to comment.