Skip to content

Commit

Permalink
Changed Array Buffer View import to randomize name to avoid bad cachi…
Browse files Browse the repository at this point in the history
…ng (#14879)
  • Loading branch information
SergioRZMasson authored Mar 18, 2024
1 parent 40d021d commit 4555cc9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/dev/core/src/Loading/sceneLoader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import type { Geometry } from "../Meshes/geometry";
import type { Light } from "../Lights/light";
import { RuntimeError, ErrorCodes } from "../Misc/error";
import type { ISpriteManager } from "../Sprites/spriteManager";
import { RandomGUID } from "../Misc/guid";

/**
* Type used for the success callback of ImportMesh
Expand Down Expand Up @@ -660,7 +661,7 @@ export class SceneLoader {
file = sceneFile;
} else if (ArrayBuffer.isView(sceneFilename)) {
url = "";
name = "arrayBuffer";
name = RandomGUID();
rawData = sceneFilename as ArrayBufferView;
} else if (typeof sceneFilename === "string" && sceneFilename.startsWith("data:")) {
url = sceneFilename;
Expand Down

0 comments on commit 4555cc9

Please sign in to comment.