Compare commits

...

5 Commits

Author SHA1 Message Date
semantic-release-bot a53c3784e4 chore(release): 0.1.0-develop.5 [skip ci]
# [0.1.0-develop.5](https://git.lumeweb.com/LumeWeb/libs5-transport-hyper/compare/v0.1.0-develop.4...v0.1.0-develop.5) (2023-08-31)

### Bug Fixes

* change approach to make socket optional ([d22c757](d22c757c52))
2023-08-31 22:47:30 +00:00
Derrick Hammer 13b2ebe0b5
dep: update libs5 2023-08-31 18:46:45 -04:00
Derrick Hammer 0c10129cd0
Merge remote-tracking branch 'origin/develop' into develop 2023-08-31 18:45:47 -04:00
Derrick Hammer 2c8d3a2716
dep: update libs5 2023-08-31 18:45:39 -04:00
Derrick Hammer d22c757c52
fix: change approach to make socket optional 2023-08-31 18:44:58 -04:00
4 changed files with 22 additions and 11 deletions

View File

@ -1,3 +1,10 @@
# [0.1.0-develop.5](https://git.lumeweb.com/LumeWeb/libs5-transport-hyper/compare/v0.1.0-develop.4...v0.1.0-develop.5) (2023-08-31)
### Bug Fixes
* change approach to make socket optional ([d22c757](https://git.lumeweb.com/LumeWeb/libs5-transport-hyper/commit/d22c757c520e38f71ef0a303a3e116013555d01b))
# [0.1.0-develop.4](https://git.lumeweb.com/LumeWeb/libs5-transport-hyper/compare/v0.1.0-develop.3...v0.1.0-develop.4) (2023-08-31) # [0.1.0-develop.4](https://git.lumeweb.com/LumeWeb/libs5-transport-hyper/compare/v0.1.0-develop.3...v0.1.0-develop.4) (2023-08-31)

12
package-lock.json generated
View File

@ -1,14 +1,14 @@
{ {
"name": "@lumeweb/libs5-transport-hyper", "name": "@lumeweb/libs5-transport-hyper",
"version": "0.1.0-develop.2", "version": "0.1.0-develop.4",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "@lumeweb/libs5-transport-hyper", "name": "@lumeweb/libs5-transport-hyper",
"version": "0.1.0-develop.2", "version": "0.1.0-develop.4",
"dependencies": { "dependencies": {
"@lumeweb/libs5": "^0.1.0-develop.11", "@lumeweb/libs5": "^0.1.0-develop.13",
"streamx": "^2.15.1" "streamx": "^2.15.1"
}, },
"devDependencies": { "devDependencies": {
@ -1828,9 +1828,9 @@
} }
}, },
"node_modules/@lumeweb/libs5": { "node_modules/@lumeweb/libs5": {
"version": "0.1.0-develop.11", "version": "0.1.0-develop.13",
"resolved": "https://registry.npmjs.org/@lumeweb/libs5/-/libs5-0.1.0-develop.11.tgz", "resolved": "https://registry.npmjs.org/@lumeweb/libs5/-/libs5-0.1.0-develop.13.tgz",
"integrity": "sha512-xcajSNdXx19IYFzArXdGb9yQBexlzuXw0r2SGpdTUivkPRQN8xzaJ3IhqJifpjYMKWmIMKRocbrjIP7F/OGd+Q==", "integrity": "sha512-iZfXlTF6MtHqgBoUOGj1d90LlMBXjiGzXjqlueKvhusMxKzMwgvhOZLQmp1klNx/BGbG02eYRswCsYXhcQDp7w==",
"dependencies": { "dependencies": {
"@noble/curves": "^1.1.0", "@noble/curves": "^1.1.0",
"@noble/hashes": "^1.3.1", "@noble/hashes": "^1.3.1",

View File

@ -1,6 +1,6 @@
{ {
"name": "@lumeweb/libs5-transport-hyper", "name": "@lumeweb/libs5-transport-hyper",
"version": "0.1.0-develop.4", "version": "0.1.0-develop.5",
"type": "module", "type": "module",
"main": "lib/index.js", "main": "lib/index.js",
"repository": { "repository": {
@ -24,7 +24,7 @@
"lib" "lib"
], ],
"dependencies": { "dependencies": {
"@lumeweb/libs5": "^0.1.0-develop.11", "@lumeweb/libs5": "^0.1.0-develop.13",
"streamx": "^2.15.1" "streamx": "^2.15.1"
} }
} }

View File

@ -3,6 +3,8 @@ import { URL } from "url";
import { Buffer } from "buffer"; import { Buffer } from "buffer";
import { Readable } from "streamx"; import { Readable } from "streamx";
type OmitSocket<T> = Omit<T, "socket">;
export default class HyperTransportPeer extends BasePeer { export default class HyperTransportPeer extends BasePeer {
private _peer: any; private _peer: any;
private _muxer: any; private _muxer: any;
@ -11,14 +13,16 @@ export default class HyperTransportPeer extends BasePeer {
private _pipe?: any; private _pipe?: any;
constructor( constructor(
options: PeerConstructorOptions & { options: OmitSocket<PeerConstructorOptions> & {
peer: any; peer: any;
muxer: any; muxer: any;
protocol: string; protocol: string;
socket?: any;
}, },
) { ) {
super(options); super({
...options,
socket: undefined,
});
const { peer, muxer, protocol } = options; const { peer, muxer, protocol } = options;
this._peer = peer; this._peer = peer;
this._muxer = muxer; this._muxer = muxer;