Skip to content

Commit 67404f6

Browse files
author
Adam Rudd
committed
Merge pull request mqttjs#93 from adamvr/will-qos-default-0
Default will qos to 0 if not supplied or invalid
2 parents ea09954 + 742c44a commit 67404f6

File tree

2 files changed

+1
-5
lines changed

2 files changed

+1
-5
lines changed

lib/generate.js

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,10 +71,6 @@ module.exports.connect = function(opts) {
7171
} else {
7272
length += will.payload.length + 2;
7373
}
74-
// It must have a number qos
75-
if ('number' !== typeof will.qos) {
76-
return new Error('Invalid will - invalid qos');
77-
}
7874
}
7975

8076
// Username

test/connection.transmit.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -421,7 +421,7 @@ module.exports = function() {
421421
this.conn.connect(fixture);
422422
});
423423

424-
it('should reject will with invalid qos', function(done) {
424+
it.skip('should reject will with invalid qos', function(done) {
425425
var fixture = {
426426
protocolId: 'MQIsdp',
427427
protocolVersion: 3,

0 commit comments

Comments
 (0)