From bb3586beabd96bd5f573699e52e62c3af5a61b1d Mon Sep 17 00:00:00 2001 From: Alex Hultman Date: Fri, 6 Mar 2026 08:50:19 +0000 Subject: [PATCH] [GitHub Actions] Updated ubuntu-24.04-arm binaries --- source_commit | 2 +- uws.js | 11 +++++------ 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/source_commit b/source_commit index 0dce1d59..7e14d980 100644 --- a/source_commit +++ b/source_commit @@ -1 +1 @@ -eec323022d80a793649cae43b6ef7a164527b262 +279e47a116271f2b797d7365b1d7f27ca7ed9cc4 diff --git a/uws.js b/uws.js index edd1e0e8..24991207 100644 --- a/uws.js +++ b/uws.js @@ -19,21 +19,20 @@ module.exports = (() => { try { return require('./uws_' + process.platform + '_' + process.arch + '_' + process.versions.modules + '.node'); } catch (e) { - throw new Error('This version of uWS.js (v20.60.0) supports only Node.js versions 20, 22, 24 and 25 on (glibc) Linux, macOS and Windows, on Tier 1 platforms (https://github.com/nodejs/node/blob/master/BUILDING.md#platform-list).\n\n' + e.toString()); + throw new Error('This version of uWS.js (v20.59.0) supports only Node.js versions 20, 22, 24 and 25 on (glibc) Linux, macOS and Windows, on Tier 1 platforms (https://github.com/nodejs/node/blob/master/BUILDING.md#platform-list).\n\n' + e.toString()); } })(); module.exports.DeclarativeResponse = class DeclarativeResponse { constructor() { this.instructions = []; - this.encoder = new TextEncoder(); } // Utility method to encode text and append instruction _appendInstruction(opcode, ...text) { this.instructions.push(opcode); text.forEach(str => { - const bytes = (typeof str === 'string') ? this.encoder.encode(str) : str; + const bytes = (typeof str === 'string') ? new TextEncoder().encode(str) : str; this.instructions.push(bytes.length, ...bytes); }); } @@ -41,7 +40,7 @@ module.exports.DeclarativeResponse = class DeclarativeResponse { // Utility method to append 2-byte length text in little-endian format _appendInstructionWithLength(opcode, text) { this.instructions.push(opcode); - const bytes = this.encoder.encode(text); + const bytes = new TextEncoder().encode(text); const length = bytes.length; this.instructions.push(length & 0xff, (length >> 8) & 0xff, ...bytes); } @@ -53,8 +52,8 @@ module.exports.DeclarativeResponse = class DeclarativeResponse { write(value) { return this._appendInstructionWithLength(5, value), this; } writeParameterValue(key) { return this._appendInstruction(6, key), this; } - end(value) { - const bytes = (typeof str === 'string') ? this.encoder.encode(str) : str; + end(str) { + const bytes = (typeof str === 'string') ? new TextEncoder().encode(str) : str; const length = bytes.length; this.instructions.push(0, length & 0xff, (length >> 8) & 0xff, ...bytes); return new Uint8Array(this.instructions).buffer;