summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--apps/files_sharing/js/sharedfilelist.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/apps/files_sharing/js/sharedfilelist.js b/apps/files_sharing/js/sharedfilelist.js
index 7b490b3d557..3446cb37a87 100644
--- a/apps/files_sharing/js/sharedfilelist.js
+++ b/apps/files_sharing/js/sharedfilelist.js
@@ -82,7 +82,10 @@
// add row with expiration date for link only shares - influenced by _createRow of filelist
if (this._linksOnly) {
- var expirationTimestamp = moment(fileData.shares[0].expiration).valueOf();
+ var expirationTimestamp = 0;
+ if(fileData.shares[0].expiration !== null) {
+ expirationTimestamp = moment(fileData.shares[0].expiration).valueOf();
+ }
$tr.attr('data-expiration', expirationTimestamp);
// date column (1000 milliseconds to seconds, 60 seconds, 60 minutes, 24 hours)