Fix Version/s: 7.x-1.9
The islandora pdf solution pack will create a download link for a pdf, even if the datastream (OBJ) does not exist.
It should check that the datastream exists, and do a datastream access check on the OBJ DSID before the link is generated.
When viewing a pdf object in islandora, if for some reason the 'OBJ' datastream does not exist, a download link for the non existent datastream is still created and printed on the object page in the template.
Add a datastream access check for the OBJ datastream, and check that the OBJ datastream exists before generating a download link.
- Create object with the PDF CModel
- Add PDF to said object and ingest
- view object (download link exists)
- delete the OBJ datastream
- view object (download link is not shown)
This should have very little impact on existing installations, however if the new datastream access check fails on the pdf's OBJ datastream or the OBJ datastream does not exist, the 'islandora_download_link' variable will not be present in the template var's further down the processing chain. This should be a non issue, as the standard practice when working in template_preprocessing function implementations is to check if the variable exists first.
discoverygarden inc. | Managing Digital Content