Skip to content

Commit

Permalink
Merge pull request #525 from NatLibFi/fix-loadvoc-update-contains-uri…
Browse files Browse the repository at this point in the history
…-performance

Much faster updating of existing large vocabulary
  • Loading branch information
osma authored Aug 30, 2021
2 parents 8ccd62c + d333e37 commit 0498081
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion annif/corpus/subject.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ def append(self, uri, label, notation):
self._append(subject_id, uri, label, notation)

def contains_uri(self, uri):
return uri in self._uris
return uri in self._uri_idx

def by_uri(self, uri, warnings=True):
"""return the subject index of a subject by its URI, or None if not found.
Expand Down

0 comments on commit 0498081

Please sign in to comment.