This commit is contained in:
Cory McWilliams 2024-06-06 19:11:48 -04:00
parent e4b6c81024
commit f66cf0f802

View File

@ -815,24 +815,6 @@ function setGlobalSettings(settings) {
} }
} }
/**
* TODOC
* @param {*} data
* @param {*} bytes
* @returns
*/
function startsWithBytes(data, bytes) {
if (data.byteLength >= bytes.length) {
let dataBytes = new Uint8Array(data.slice(0, bytes.length));
for (let i = 0; i < bytes.length; i++) {
if (dataBytes[i] !== bytes[i] && bytes[i] !== null) {
return;
}
}
return true;
}
}
/** /**
* TODOC * TODOC
* @param {*} response * @param {*} response