Compare commits

...

2 Commits

Author SHA1 Message Date
Derrick Hammer 85cc802977
*update dist 2023-04-16 19:00:57 -04:00
Derrick Hammer eb65447adb
*convert data to buffer 2023-04-16 19:00:33 -04:00
2 changed files with 2 additions and 2 deletions

View File

@ -196,7 +196,7 @@ class MultiSocketProxy extends proxy_js_1.default {
const message = await peer.channel.addMessage({ const message = await peer.channel.addMessage({
encoding: writeSocketEncoding, encoding: writeSocketEncoding,
onmessage(m) { onmessage(m) {
self._sockets.get(m.id)?.push(m.data); self._sockets.get(m.id)?.push(b4a_1.default.from(m.data));
}, },
}); });
this.update(await this._getPublicKey(peer), { this.update(await this._getPublicKey(peer), {

View File

@ -250,7 +250,7 @@ export default class MultiSocketProxy extends Proxy {
const message = await peer.channel.addMessage({ const message = await peer.channel.addMessage({
encoding: writeSocketEncoding, encoding: writeSocketEncoding,
onmessage(m: WriteSocketRequest) { onmessage(m: WriteSocketRequest) {
self._sockets.get(m.id)?.push(m.data); self._sockets.get(m.id)?.push(b4a.from(m.data));
}, },
}); });
this.update(await this._getPublicKey(peer), { this.update(await this._getPublicKey(peer), {