devicestack
Advanced tools
Comparing version 1.1.2 to 1.1.3
@@ -128,3 +128,4 @@ var EventEmitter2 = require('eventemitter2').EventEmitter2 | ||
Connection.prototype.toJSON = function() { | ||
var json = _.clone(this.attributes, true); | ||
var parse = JSON.deserialize || JSON.parse; | ||
var json = parse(JSON.stringify(this.attributes)); | ||
json.device = this.device ? this.device.toJSON() : undefined; | ||
@@ -131,0 +132,0 @@ return json; |
@@ -110,3 +110,4 @@ var EventEmitter2 = require('eventemitter2').EventEmitter2 | ||
Device.prototype.toJSON = function() { | ||
var json = _.clone(this.attributes, true); | ||
var parse = JSON.deserialize || JSON.parse; | ||
var json = parse(JSON.stringify(this.attributes)); | ||
json.connection = this.connection ? { id: this.connection.id } : undefined; | ||
@@ -113,0 +114,0 @@ return json; |
@@ -110,3 +110,3 @@ var EventEmitter2 = require('eventemitter2').EventEmitter2 | ||
if (self.unwrapFrame) { | ||
unwrappedFrame = self.unwrapFrame(_.clone(nextFrame)); | ||
var unwrappedFrame = self.unwrapFrame(_.clone(nextFrame)); | ||
if (self.log) self.log('receive unwrapped frame: ' + unwrappedFrame.toHexDebug()); | ||
@@ -113,0 +113,0 @@ self.emit('receive', unwrappedFrame); |
{ | ||
"name": "devicestack", | ||
"version": "1.1.2", | ||
"version": "1.1.3", | ||
"description": "This module helps you to represent a device and its protocol.", | ||
@@ -5,0 +5,0 @@ "private": false, |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
87598
1687