Skip to content
This repository was archived by the owner on Sep 10, 2021. It is now read-only.

Commit 7213ffd

Browse files
committed
ENH: refs #975. Append .zip to share links on multi bitstream items
1 parent 11a2327 commit 7213ffd

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

core/controllers/ShareController.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -361,7 +361,12 @@ function linksAction()
361361
break;
362362
case 'item':
363363
$dao = $this->Item->load($id);
364+
$headRev = $this->Item->getLastRevision($dao);
364365
$name = $dao->getName();
366+
if(count($headRev->getBitstreams()) > 1)
367+
{
368+
$name .= '.zip';
369+
}
365370
break;
366371
default:
367372
throw new Zend_Exception('Invalid type', 400);

0 commit comments

Comments
 (0)