1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

update download function

This commit is contained in:
Luke Pulverenti 2016-03-29 15:08:10 -04:00
parent d6c9993abe
commit e65500d84e
5 changed files with 14 additions and 8 deletions

View file

@ -981,10 +981,17 @@
break;
case 'download':
{
var downloadHref = ApiClient.getUrl("Items/" + itemId + "/Download", {
api_key: ApiClient.accessToken()
require(['fileDownloader'], function (fileDownloader) {
var downloadHref = ApiClient.getUrl("Items/" + itemId + "/Download", {
api_key: ApiClient.accessToken()
});
fileDownloader([{
url: downloadHref,
itemId: itemId
}]);
});
window.location.href = downloadHref;
break;
}