Skip to content

Commit b373beb

Browse files
committed
Use manifest version in XHR cache-busting param
Replaces Date.now() with this.manifestVersionFound in the XHR GET request URL parameter to ensure cache-busting uses the manifest version instead of a timestamp.
1 parent 9cfad22 commit b373beb

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

server-client/src/data/babylon.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24385,7 +24385,7 @@
2438524385
var targetStore;
2438624386
targetStore = -1 !== url.indexOf(".babylon") ? "scenes" : "textures";
2438724387
var fileData, xhr = new XMLHttpRequest;
24388-
xhr.open("GET", url + "?" + Date.now(), !0), useArrayBuffer && (xhr.responseType = "arraybuffer"), progressCallback && (xhr.onprogress = progressCallback), xhr.addEventListener("load", function () {
24388+
xhr.open("GET", url + "?" + this.manifestVersionFound, !0), useArrayBuffer && (xhr.responseType = "arraybuffer"), progressCallback && (xhr.onprogress = progressCallback), xhr.addEventListener("load", function () {
2438924389
if (200 === xhr.status || xhr.status < 400 && BABYLON.Tools.ValidateXHRData(xhr, useArrayBuffer ? 6 : 1))
2439024390
if (fileData = useArrayBuffer ? xhr.response : xhr.responseText, !_this.hasReachedQuota && _this.db) {
2439124391
var newFile, transaction = _this.db.transaction([targetStore], "readwrite");

0 commit comments

Comments
 (0)