diff options
author | 2022-09-14 21:34:29 -0700 | |
---|---|---|
committer | 2022-09-14 21:34:29 -0700 | |
commit | ac949f8181d165dbcb159cf7aec9a75bce6280f1 (patch) | |
tree | d010cef59d939a113a62f8157eea586dd70513b3 /src | |
parent | 48c2c8c04974c8bf1c871c25c28cab4cc657cdde (diff) | |
download | bun-ac949f8181d165dbcb159cf7aec9a75bce6280f1.tar.gz bun-ac949f8181d165dbcb159cf7aec9a75bce6280f1.tar.zst bun-ac949f8181d165dbcb159cf7aec9a75bce6280f1.zip |
Fix issue with websockets callback not registering in canary
Diffstat (limited to 'src')
-rw-r--r-- | src/http/websocket_http_client.zig | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/src/http/websocket_http_client.zig b/src/http/websocket_http_client.zig index cba0b2cae..53caf36d9 100644 --- a/src/http/websocket_http_client.zig +++ b/src/http/websocket_http_client.zig @@ -147,14 +147,14 @@ pub fn NewHTTPUpgradeClient(comptime ssl: bool) type { Socket.configure( ctx, HTTPClient, - .{ - .onOpen = handleOpen, - .onClose = handleClose, - .onData = handleData, - .onWritable = handleWritable, - .onTimeout = handleTimeout, - .onConnectError = handleConnectError, - .onEnd = handleEnd, + struct { + pub const onOpen = handleOpen; + pub const onClose = handleClose; + pub const onData = handleData; + pub const onWritable = handleWritable; + pub const onTimeout = handleTimeout; + pub const onConnectError = handleConnectError; + pub const onEnd = handleEnd; }, ); if (is_new_loop) { @@ -816,13 +816,13 @@ pub fn NewWebSocketClient(comptime ssl: bool) type { Socket.configure( ctx, WebSocket, - .{ - .onClose = handleClose, - .onData = handleData, - .onWritable = handleWritable, - .onTimeout = handleTimeout, - .onConnectError = handleConnectError, - .onEnd = handleEnd, + struct { + pub const onClose = handleClose; + pub const onData = handleData; + pub const onWritable = handleWritable; + pub const onTimeout = handleTimeout; + pub const onConnectError = handleConnectError; + pub const onEnd = handleEnd; }, ); } |