Skip to content

Commit 60c9721

Browse files
committed
0.4.26
1 parent ecafcd5 commit 60c9721

File tree

10 files changed

+29
-25
lines changed

10 files changed

+29
-25
lines changed

dist/webduino-all.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2496,7 +2496,7 @@ Paho.MQTT = (function (global) {
24962496
})(window);
24972497

24982498
var webduino = webduino || {
2499-
version: '0.4.25'
2499+
version: '0.4.26'
25002500
};
25012501

25022502
if (typeof exports !== 'undefined') {

dist/webduino-all.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/webduino-base.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2496,7 +2496,7 @@ Paho.MQTT = (function (global) {
24962496
})(window);
24972497

24982498
var webduino = webduino || {
2499-
version: '0.4.25'
2499+
version: '0.4.26'
25002500
};
25012501

25022502
if (typeof exports !== 'undefined') {

dist/webduino-base.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/classes/webduino.transport.NodeMqttTransport.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -786,7 +786,7 @@ <h3 class="name"><code>CONNECT_TIMEOUT</code></h3>
786786
<div class="meta">
787787
<p>
788788
Defined in
789-
<a href="../files/src_transport_NodeMqttTransport.js.html#l197"><code>src&#x2F;transport&#x2F;NodeMqttTransport.js:197</code></a>
789+
<a href="../files/src_transport_NodeMqttTransport.js.html#l201"><code>src&#x2F;transport&#x2F;NodeMqttTransport.js:201</code></a>
790790
</p>
791791

792792

@@ -812,7 +812,7 @@ <h3 class="name"><code>KEEPALIVE_INTERVAL</code></h3>
812812
<div class="meta">
813813
<p>
814814
Defined in
815-
<a href="../files/src_transport_NodeMqttTransport.js.html#l188"><code>src&#x2F;transport&#x2F;NodeMqttTransport.js:188</code></a>
815+
<a href="../files/src_transport_NodeMqttTransport.js.html#l192"><code>src&#x2F;transport&#x2F;NodeMqttTransport.js:192</code></a>
816816
</p>
817817

818818

@@ -838,7 +838,7 @@ <h3 class="name"><code>MAX_PACKET_SIZE</code></h3>
838838
<div class="meta">
839839
<p>
840840
Defined in
841-
<a href="../files/src_transport_NodeMqttTransport.js.html#l206"><code>src&#x2F;transport&#x2F;NodeMqttTransport.js:206</code></a>
841+
<a href="../files/src_transport_NodeMqttTransport.js.html#l210"><code>src&#x2F;transport&#x2F;NodeMqttTransport.js:210</code></a>
842842
</p>
843843

844844

@@ -864,7 +864,7 @@ <h3 class="name"><code>RECONNECT_PERIOD</code></h3>
864864
<div class="meta">
865865
<p>
866866
Defined in
867-
<a href="../files/src_transport_NodeMqttTransport.js.html#l179"><code>src&#x2F;transport&#x2F;NodeMqttTransport.js:179</code></a>
867+
<a href="../files/src_transport_NodeMqttTransport.js.html#l183"><code>src&#x2F;transport&#x2F;NodeMqttTransport.js:183</code></a>
868868
</p>
869869

870870

docs/data.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2299,7 +2299,7 @@
22992299
},
23002300
{
23012301
"file": "src/transport/NodeMqttTransport.js",
2302-
"line": 179,
2302+
"line": 183,
23032303
"description": "Reconnect period when MQTT connection goes down. Measured in seconds.",
23042304
"itemtype": "property",
23052305
"name": "RECONNECT_PERIOD",
@@ -2310,7 +2310,7 @@
23102310
},
23112311
{
23122312
"file": "src/transport/NodeMqttTransport.js",
2313-
"line": 188,
2313+
"line": 192,
23142314
"description": "MQTT keepalive interval. Measured in seconds.",
23152315
"itemtype": "property",
23162316
"name": "KEEPALIVE_INTERVAL",
@@ -2321,7 +2321,7 @@
23212321
},
23222322
{
23232323
"file": "src/transport/NodeMqttTransport.js",
2324-
"line": 197,
2324+
"line": 201,
23252325
"description": "Time to wait before throwing connection timeout exception. Measured in seconds.",
23262326
"itemtype": "property",
23272327
"name": "CONNECT_TIMEOUT",
@@ -2332,7 +2332,7 @@
23322332
},
23332333
{
23342334
"file": "src/transport/NodeMqttTransport.js",
2335-
"line": 206,
2335+
"line": 210,
23362336
"description": "Maximum packet size in KB.",
23372337
"itemtype": "property",
23382338
"name": "MAX_PACKET_SIZE",

docs/files/src_transport_NodeMqttTransport.js.html

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -174,20 +174,24 @@ <h1>src/transport/NodeMqttTransport.js <small>File</small></h1>
174174
}
175175

176176
function onMessage(topic, message, packet) {
177-
var dest = topic,
178-
oldStatus = this._status;
177+
try {
178+
var dest = topic,
179+
oldStatus = this._status;
179180

180-
switch (dest.substr(dest.lastIndexOf(&#x27;/&#x27;) + 1)) {
181+
switch (dest.substr(dest.lastIndexOf(&#x27;/&#x27;) + 1)) {
181182

182-
case &#x27;STATUS&#x27;:
183-
this._status = message.toString();
184-
detectStatusChange(this, this._status, oldStatus);
185-
break;
183+
case &#x27;STATUS&#x27;:
184+
this._status = message.toString();
185+
detectStatusChange(this, this._status, oldStatus);
186+
break;
186187

187-
default:
188-
(this._status === STATUS.OK) &amp;&amp; this.emit(TransportEvent.MESSAGE, message);
189-
break;
188+
default:
189+
(this._status === STATUS.OK) &amp;&amp; this.emit(TransportEvent.MESSAGE, message);
190+
break;
190191

192+
}
193+
} catch (err) {
194+
this.emit(TransportEvent.ERROR, err);
191195
}
192196
}
193197

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "webduino-js",
3-
"version": "0.4.25",
3+
"version": "0.4.26",
44
"main": "index.js",
55
"description": "The Webduino Javascript Core, for Browser and Node.js",
66
"repository": "https://github.com/webduinoio/webduino-js.git",

src/webduino.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
var webduino = webduino || {
2-
version: '0.4.25'
2+
version: '0.4.26'
33
};
44

55
if (typeof exports !== 'undefined') {

0 commit comments

Comments
 (0)