| 425 | } |
| 426 | |
| 427 | function g(e) { |
| 428 | if (!e) throw new Error("invalid buffer " + e); |
| 429 | if ("Uint8Array" === e.constructor.name || e.constructor === Uint8Array) return e; |
| 430 | "string" == typeof e && (e = Buffer.from(e)); |
| 431 | const o = new Uint8Array(e.length); |
| 432 | for (let t = 0; t < e.length; t++) o[t] = e[t]; |
| 433 | return o |
| 434 | } |
| 435 | exports.requestCmdForType = i, exports.clientRequestCmdForType = m, exports.wrapDebugMessageData = b, exports.wrapOutgoingToProto = function(e, n, r, m = !1) { |
| 436 | let b = null; |
| 437 | switch (n) { |