New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

adonisjs-websocket

Package Overview
Dependencies
Maintainers
0
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

adonisjs-websocket - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

2

build/providers/websocket_provider.d.ts

@@ -16,3 +16,3 @@ import type { ApplicationService } from '@adonisjs/core/types';

*/
broadcast: (url: string, data: string) => void;
broadcast: (url: string, data: string) => Promise<void>;
};

@@ -19,0 +19,0 @@ }

@@ -91,5 +91,5 @@ import { Router } from '@adonisjs/http-server';

this.app.container.singleton('websocket', () => ({
broadcast: (url, data) => {
broadcast: async (url, data) => {
if (publisher) {
publisher.publish('websocket::broadcast', JSON.stringify({
await publisher.publish('websocket::broadcast', JSON.stringify({
channel: url,

@@ -143,5 +143,5 @@ data,

});
ws.broadcast = (data, options) => {
ws.broadcast = async (data, options) => {
if (publisher) {
publisher.publish('websocket::broadcast', JSON.stringify({
await publisher.publish('websocket::broadcast', JSON.stringify({
channel: url,

@@ -148,0 +148,0 @@ data,

@@ -6,3 +6,3 @@ import { WebSocket as WebSocketBase } from 'ws';

ignoreSelf?: boolean;
}) => void;
}) => Promise<void>;
}
{
"name": "adonisjs-websocket",
"description": "Websocket provider for AdonisJS",
"version": "0.2.0",
"version": "0.2.1",
"engines": {

@@ -6,0 +6,0 @@ "node": ">=20.6.0"

@@ -50,3 +50,3 @@ # AdonisJS Websocket

// you can enable redis in `config/websocket.ts` to broadcast on all web server instances
ws.broadcast('Hello everyone!')
await ws.broadcast('Hello everyone!')
},

@@ -53,0 +53,0 @@ [

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc