Skip to content

Commit

Permalink
fix missing error handler on redis client
Browse files Browse the repository at this point in the history
  • Loading branch information
DoobleD committed Nov 8, 2024
1 parent 3994280 commit faff6e9
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
### Unreleased

### [2.0.6] - 2024-11-08

- fix missing error handler on redis client [#45](https://github.com/haraka/haraka-plugin-redis/issues/45)

### [2.0.5] - 2024-10-22

- html/client: updated dnsbl -> dns-list
Expand Down
3 changes: 3 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,9 @@ exports.redis_subscribe_all_results = async function (next) {
if (this.pubsub) return // already subscribed?

this.pubsub = redis.createClient(this.redisCfg.pubsub)
this.pubsub.on('error', (err) => {
this.logerror(err.message)
})
await this.pubsub.connect()

await this.pubsub.pSubscribe('result-*', (message, channel) => {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "haraka-plugin-watch",
"version": "2.0.5",
"version": "2.0.6",
"description": "Watch live SMTP traffic in a web interface",
"main": "index.js",
"files": [
Expand Down

0 comments on commit faff6e9

Please sign in to comment.