Skip to content

Commit

Permalink
Bugfix remove try and catch
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinFechner committed Jun 7, 2022
1 parent d452955 commit 95aaa53
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions content/edweb-api.xql
Original file line number Diff line number Diff line change
Expand Up @@ -1041,7 +1041,7 @@ declare function edwebapi:get-objects(
$root as xs:string
) as node()*
{
try {
(: try { :)
if (xmldb:collection-available($data-collection||$collection))
then
util:eval("collection($data-collection||$collection)//"||$root)
Expand All @@ -1051,9 +1051,9 @@ declare function edwebapi:get-objects(
else
error(xs:QName("edwebapi:get-objects-002"), "Can't find collection or resource. data-collection: "
||$data-collection||", collection/resource: "||$collection)
}
catch * { error(xs:QName("edwebapi:get-objects-001"), "Can't load objects. data-collection: "
||$data-collection||", collection: "||$collection||", root: "||$root)
(: } :)
(: catch * { error(xs:QName("edwebapi:get-objects-001"), "Can't load objects. data-collection: " :)
(: ||$data-collection||", collection: "||$collection||", root: "||$root) :)
}
(: TODO: Hack for exist-db 4.6.1 This can probably be solved more elegantly :)
(:~ util:eval("collection('" || $collection || "')//" || $xpath) ~:)
Expand Down

0 comments on commit 95aaa53

Please sign in to comment.