ui: better index check

This commit is contained in:
nick-delirium 2025-01-28 14:18:36 +01:00
parent 312db29d23
commit 4c6f23e31f
No known key found for this signature in database
GPG key ID: 93ABD695DF5FDBA0

View file

@ -17,9 +17,8 @@ export default class MFileReader extends RawMessageReader {
}
public checkForIndexes() {
// 0xff 0xff 0xff 0xff 0xff 0xff 0xff 0xff = no indexes + weird fail over (don't ask)
const skipIndexes = this.readCustomIndex(this.buf.slice(0, 8)) === 72057594037927940
|| this.readCustomIndex(this.buf.slice(0, 9)) === 72057594037927940
// 0xff 0xff 0xff 0xff 0xff 0xff 0xff 0xff = no indexes
const skipIndexes = this.buf.slice(0,8).every(b => b === 0xff)
if (skipIndexes) {
if (!this.noIndexes) {