From 0012b47c10d01d7fef7df57ecfaf4b7078f2e73c Mon Sep 17 00:00:00 2001 From: 40handz Date: Thu, 19 Mar 2026 10:00:43 -0400 Subject: [PATCH 1/2] Fix broken links in README --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 0137f5d..a643396 100644 --- a/README.md +++ b/README.md @@ -170,7 +170,7 @@ pusher.sendToUser("user-1", "test_event", { message: "hello world" }) ### Excluding event recipients -In order to avoid the client that triggered the event from also receiving it, a `socket_id` parameter can be added to the `params` object. For more information see: . +In order to avoid the client that triggered the event from also receiving it, a `socket_id` parameter can be added to the `params` object. For more information see: . ```javascript pusher.trigger(channel, event, data, { socket_id: "1302.1081607" }) @@ -390,7 +390,7 @@ pusher pusher.get({ path: "/channels", params: params }) ``` -Information on the optional `params` and the structure of the returned JSON is defined in the [REST API reference](http://pusher.com/docs/rest_api#method-get-channels). +Information on the optional `params` and the structure of the returned JSON is defined in the [REST API reference](https://pusher.com/docs/channels/library_auth_reference/rest-api/#method-get-channels). #### Get the state of a channel @@ -398,7 +398,7 @@ Information on the optional `params` and the structure of the returned JSON is d pusher.get({ path: "/channels/[channel_name]", params: params }) ``` -Information on the optional `params` option property and the structure of the returned JSON is defined in the [REST API reference](http://pusher.com/docs/rest_api#method-get-channel). +Information on the optional `params` option property and the structure of the returned JSON is defined in the [REST API reference](https://pusher.com/docs/channels/library_auth_reference/rest-api/#method-get-channel). #### Get the list of users in a presence channel @@ -406,7 +406,7 @@ Information on the optional `params` option property and the structure of the re pusher.get({ path: "/channels/[channel_name]/users" }) ``` -The `channel_name` in the path must be a [presence channel](http://pusher.com/docs/presence). The structure of the returned JSON is defined in the [REST API reference](http://pusher.com/docs/rest_api#method-get-users). +The `channel_name` in the path must be a [presence channel](https://pusher.com/docs/channels/using_channels/presence-channels/). The structure of the returned JSON is defined in the [REST API reference](https://pusher.com/docs/channels/library_auth_reference/rest-api/#method-get-users). ### WebHooks From 65dd9ca4954f71ffa04691861786ef7b4916ba61 Mon Sep 17 00:00:00 2001 From: 40handz Date: Thu, 19 Mar 2026 10:09:38 -0400 Subject: [PATCH 2/2] Fix incorrect keepAlive option in README, replace with agent --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index a643396..d9e9a0a 100644 --- a/README.md +++ b/README.md @@ -92,12 +92,13 @@ There are a few additional options that can be used in all above methods: ```javascript const Pusher = require("pusher") +const http = require("http") const pusher = new Pusher({ // you can set other options in any of the 3 ways described above proxy: "HTTP_PROXY_URL", // optional, URL to proxy the requests through timeout: TIMEOUT, // optional, timeout for all requests in milliseconds - keepAlive: KEEP_ALIVE, // optional, enables keep-alive, defaults to false + agent: new http.Agent({ keepAlive: true }), // optional, enables keep-alive }) ```