Обновить лицензии, исторический HEADER и ссылки CORE/CONTENT

This commit is contained in:
AidarKC
2026-12-05 23:45:02 +03:00
parent 37a04dde4d
commit 6968d11693
28 changed files with 313 additions and 126 deletions
+1 -1
View File
@@ -10,7 +10,7 @@ const source = auth.split('function makeHeaderBodyBytes(')[1]?.split('\nfunction
assert.ok(source, 'production makeHeaderBodyBytes must exist');
const utf8 = value => new TextEncoder().encode(value);
const encode = vm.runInNewContext(`function makeHeaderBodyBytes(${source}\nmakeHeaderBodyBytes`, {
HEADER_DEFAULT_LICENSE: auth.match(/export const HEADER_DEFAULT_LICENSE = '([^']+)'/)[1],
HEADER_DEFAULT_LICENSE: JSON.parse(auth.match(/export const HEADER_DEFAULT_LICENSE = ("[^"]+");/)[1]),
utf8Bytes: utf8,
int8Byte: value => Uint8Array.of(value),
concatBytes: (...parts) => Uint8Array.from(parts.flatMap(part => Array.from(part))),