diff --git a/spacy/tokens/span.pyx b/spacy/tokens/span.pyx index 42fb9852d..460972369 100644 --- a/spacy/tokens/span.pyx +++ b/spacy/tokens/span.pyx @@ -311,7 +311,7 @@ cdef class Span: DOCS: https://spacy.io/api/span#similarity """ if "similarity" in self.doc.user_span_hooks: - self.doc.user_span_hooks["similarity"](self, other) + return self.doc.user_span_hooks["similarity"](self, other) if len(self) == 1 and hasattr(other, "orth"): if self[0].orth == other.orth: return 1.0