Inherit InvalidDocument and InvalidData from DiscoveryError
This commit is contained in:
parent
8149421287
commit
53fc77ac5d
1 changed files with 6 additions and 6 deletions
|
|
@ -1,7 +1,11 @@
|
||||||
module DiasporaFederation
|
module DiasporaFederation
|
||||||
module Discovery
|
module Discovery
|
||||||
|
# Raised, if there is an error while discover a new person
|
||||||
|
class DiscoveryError < RuntimeError
|
||||||
|
end
|
||||||
|
|
||||||
# Raised, if the XML structure is invalid
|
# Raised, if the XML structure is invalid
|
||||||
class InvalidDocument < RuntimeError
|
class InvalidDocument < DiscoveryError
|
||||||
end
|
end
|
||||||
|
|
||||||
# Raised, if something is wrong with the webfinger data
|
# Raised, if something is wrong with the webfinger data
|
||||||
|
|
@ -9,11 +13,7 @@ module DiasporaFederation
|
||||||
# * if the +webfinger_url+ is missing or malformed in {HostMeta.from_base_url} or {HostMeta.from_xml}
|
# * if the +webfinger_url+ is missing or malformed in {HostMeta.from_base_url} or {HostMeta.from_xml}
|
||||||
# * if the parsed XML from {WebFinger.from_xml} is incomplete
|
# * if the parsed XML from {WebFinger.from_xml} is incomplete
|
||||||
# * if the html passed to {HCard.from_html} in some way is malformed, invalid or incomplete.
|
# * if the html passed to {HCard.from_html} in some way is malformed, invalid or incomplete.
|
||||||
class InvalidData < RuntimeError
|
class InvalidData < DiscoveryError
|
||||||
end
|
|
||||||
|
|
||||||
# Raised, if there is an error while discover a new person
|
|
||||||
class DiscoveryError < RuntimeError
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue