dlcs / iiif-presentation

Allows for the creation and management of IIIF manifests
MIT License
0 stars 0 forks source link

It's possible to set the parent of a child collection to be it's child #32

Closed JackLewis-digirati closed 1 month ago

JackLewis-digirati commented 1 month ago

Currently, you can create a child, move the parent to be a child item of the child (it'll do this without modifying the child item's parent) which then causes the API to freak out when trying to figure out the slug and then crash (returning 500) with what's likely a stack overflow

We can likely stop this from happening by setting a max depth to the CTE of a query and rolling back and returning an error if it's hit