also check if structures is not empty
Merge pull request #276 from IIIF/bug-fixes

also check if structures is not empty