From e38749a65943c5da71cb717f199f77d173d46c51 Mon Sep 17 00:00:00 2001 From: alexkonst Date: Tue, 24 Mar 2020 22:26:31 +0300 Subject: [PATCH] Added passing args to disconnect method --- package.json | 2 +- src/index.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 65badb1..25800e7 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@netology-group/mqtt-client", - "version": "0.4.1", + "version": "0.4.2", "description": "MQTT client implementation for JavaScript", "files": [ "dist", diff --git a/src/index.js b/src/index.js index c275339..553064b 100644 --- a/src/index.js +++ b/src/index.js @@ -60,8 +60,8 @@ class MQTTClient { this._client.on(MQTTClient.events.MESSAGE, this._handleMessageEvent) } - disconnect () { - this._client.end() + disconnect (...args) { + this._client.end(...args) } reconnect () {