Skip to content

Commit

Permalink
fix type for Glossary.addEntryObj, #424
Browse files Browse the repository at this point in the history
  • Loading branch information
ilius committed Feb 3, 2023
1 parent 6b820a7 commit 85d0aa2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pyglossary/glossary.py
Original file line number Diff line number Diff line change
Expand Up @@ -469,7 +469,7 @@ def wordTitleStr(
def getConfig(self, name: str, default: "Optional[str]") -> "Optional[str]":
return self._config.get(name, default)

def addEntryObj(self, entry: Entry) -> None:
def addEntryObj(self, entry: "BaseEntry") -> None:
self._data.append(entry)

def newEntry(
Expand Down
2 changes: 1 addition & 1 deletion pyglossary/glossary_type.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ def wordTitleStr(
def getConfig(self, name: str, default: "Optional[str]") -> "Optional[str]":
raise NotImplementedError

def addEntryObj(self, entry: "Entry") -> None:
def addEntryObj(self, entry: "BaseEntry") -> None:
raise NotImplementedError

def newEntry(self, word: str, defi: str, defiFormat: str = "") -> "Entry":
Expand Down

0 comments on commit 85d0aa2

Please sign in to comment.