Skip to content
Snippets Groups Projects
Commit ef468865 authored by yvesn's avatar yvesn
Browse files

SSDM-5544: not showing preview icon for files which start with .

parent 33f90112
No related branches found
No related tags found
No related merge requests found
...@@ -83,9 +83,10 @@ function DataSetViewerModel(containerId, profile, entity, serverFacade, datastor ...@@ -83,9 +83,10 @@ function DataSetViewerModel(containerId, profile, entity, serverFacade, datastor
} }
this._isIconableImage = function(pathInDataSet) { this._isIconableImage = function(pathInDataSet) {
return this._hasExtension(pathInDataSet, ["jpg", "jpeg", "png", "gif"]); var filename = pathInDataSet.split('/').slice(-1)[0];
return !filename.startsWith('.') && this._hasExtension(pathInDataSet, ["jpg", "jpeg", "png", "gif"]);
} }
this._isJupyterNotebook = function(pathInDataSet) { this._isJupyterNotebook = function(pathInDataSet) {
return this._hasExtension(pathInDataSet, ["ipynb"]); return this._hasExtension(pathInDataSet, ["ipynb"]);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment