plugin XEP-0277: don't wrap DataError in failure.Failure in parseCommentUrl as it is not catched correctly:

`failure.Failure` is subclass of `BaseException` but not of `Exception`, as a result
`except Exception` doesn't catch it correctly. This is fixed by not wrapping `DataError`
in `failure.Failure` anymore.
This commit is contained in:
Goffi 2021-06-04 17:18:44 +02:00
commit 93e4021b86

View file

@ -1005,7 +1005,7 @@ class XEP_0277(object):
node = parsed_queries.get("node", [""])[0]
if not node:
raise failure.Failure(exceptions.DataError("Invalid comments link"))
raise exceptions.DataError("Invalid comments link")
return (service, node)