diff --git a/module/scripts/project/thumbnail-renderer.js b/module/scripts/project/thumbnail-renderer.js index 1dca4d9..ae72505 100644 --- a/module/scripts/project/thumbnail-renderer.js +++ b/module/scripts/project/thumbnail-renderer.js @@ -61,7 +61,7 @@ class ThumbnailReconRenderer extends ReconCellRenderer { .attr("target", "_blank") .appendTo(divContentRecon); - var bareFileName = match.name.substr('File:'.length).replaceAll(' ', '_'); + var bareFileName = (match.name.startsWith('File:') ? match.name.substr('File:'.length) : match.name).replaceAll(' ', '_'); var fileNameParts = bareFileName.split('.'); var extension = fileNameParts[fileNameParts.length - 1].toLowerCase(); if (!self.supportedExtensions.includes(extension)) {