*alias write to send to be WS compatible
This commit is contained in:
parent
c90e022795
commit
11550659d0
|
@ -1,4 +1,5 @@
|
|||
import { Duplex, DuplexEvents, Callback } from "streamx";
|
||||
import { write } from "fs";
|
||||
|
||||
const IPV4 = "IPv4";
|
||||
const IPV6 = "IPv6";
|
||||
|
@ -102,6 +103,8 @@ export default class Socket extends Duplex {
|
|||
removeEventListener = this.removeListener;
|
||||
off = this.removeListener;
|
||||
|
||||
send = write;
|
||||
|
||||
static isIP(input: string): number {
|
||||
if (Socket.isIPv4(input)) {
|
||||
return 4;
|
||||
|
|
Loading…
Reference in New Issue