nim-websock new version compatibility (#939)

This commit is contained in:
Tanguy 2023-08-02 17:10:31 +02:00 committed by GitHub
parent 56c23a286a
commit d6263bf751
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -108,7 +108,7 @@ type
flags: set[ServerFlags] flags: set[ServerFlags]
handshakeTimeout: Duration handshakeTimeout: Duration
factories: seq[ExtFactory] factories: seq[ExtFactory]
rng: Rng rng: ref HmacDrbgContext
proc secure*(self: WsTransport): bool = proc secure*(self: WsTransport): bool =
not (isNil(self.tlsPrivateKey) or isNil(self.tlsCertificate)) not (isNil(self.tlsPrivateKey) or isNil(self.tlsCertificate))
@ -327,7 +327,7 @@ proc new*(
tlsFlags: set[TLSFlags] = {}, tlsFlags: set[TLSFlags] = {},
flags: set[ServerFlags] = {}, flags: set[ServerFlags] = {},
factories: openArray[ExtFactory] = [], factories: openArray[ExtFactory] = [],
rng: Rng = nil, rng: ref HmacDrbgContext = nil,
handshakeTimeout = DefaultHeadersTimeout): T {.public.} = handshakeTimeout = DefaultHeadersTimeout): T {.public.} =
## Creates a secure WebSocket transport ## Creates a secure WebSocket transport
@ -346,7 +346,7 @@ proc new*(
upgrade: Upgrade, upgrade: Upgrade,
flags: set[ServerFlags] = {}, flags: set[ServerFlags] = {},
factories: openArray[ExtFactory] = [], factories: openArray[ExtFactory] = [],
rng: Rng = nil, rng: ref HmacDrbgContext = nil,
handshakeTimeout = DefaultHeadersTimeout): T {.public.} = handshakeTimeout = DefaultHeadersTimeout): T {.public.} =
## Creates a clear-text WebSocket transport ## Creates a clear-text WebSocket transport