mqtt 5.6.1 → 5.6.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "mqtt",
3
3
  "description": "A library for the MQTT protocol",
4
- "version": "5.6.1",
4
+ "version": "5.6.2",
5
5
  "contributors": [
6
6
  "Adam Rudd <adamvrr@gmail.com>",
7
7
  "Matteo Collina <matteo.collina@gmail.com> (https://github.com/mcollina)",
@@ -80,7 +80,16 @@ function connect(
80
80
  parsed.port = Number(parsed.port)
81
81
  }
82
82
 
83
- opts = { ...parsed, ...opts } as IClientOptions
83
+ opts = {
84
+ ...{
85
+ port: parsed.port,
86
+ host: parsed.hostname,
87
+ protocol: parsed.protocol,
88
+ query: parsed.query,
89
+ auth: parsed.auth,
90
+ },
91
+ ...opts,
92
+ } as IClientOptions
84
93
 
85
94
  if (opts.protocol === null) {
86
95
  throw new Error('Missing protocol')