mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 16:14:35 +02:00
Better code fix for preview
being more specific on the validation for the unresolvable relative path. checking now if the path start with "file:///~" instead of only: "file:/" This was too much restrictive since those direct path works and wouldn't return a preview: Ex: "file://MYSERVER/folder/100_0057.jpg"
This commit is contained in:
parent
d31f161d88
commit
8d217d215f
1 changed files with 1 additions and 1 deletions
|
@ -2890,7 +2890,7 @@ function createTextureProperty(property, elProperty) {
|
||||||
|
|
||||||
let imageLoad = function(url) {
|
let imageLoad = function(url) {
|
||||||
elDiv.style.display = null;
|
elDiv.style.display = null;
|
||||||
if (url.slice(0, 5).toLowerCase() === "atp:/" || url.slice(0, 6).toLowerCase() === "file:/") {
|
if (url.slice(0, 5).toLowerCase() === "atp:/" || url.slice(0, 9).toLowerCase() === "file:///~") {
|
||||||
elImage.src = "";
|
elImage.src = "";
|
||||||
elImage.style.display = "none";
|
elImage.style.display = "none";
|
||||||
elDiv.classList.remove("with-texture");
|
elDiv.classList.remove("with-texture");
|
||||||
|
|
Loading…
Reference in a new issue