Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

devicestack

Package Overview
Dependencies
Maintainers
1
Versions
54
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

devicestack - npm Package Compare versions

Comparing version 1.3.2 to 1.3.3

11

lib/deviceguider.js

@@ -75,2 +75,4 @@ var util = require('util'),

var connecting = false;
this.deviceLoader.on('plug', function(device) {

@@ -84,3 +86,8 @@ self.currentState.plugged.push(device);

if (self.currentState.connectionMode === 'autoconnect' || self.currentState.connectionMode === 'autoconnectOne' && self.currentState.connected.length === 0) {
self.connectDevice(device);
if (!connecting) {
self.connectDevice(device, function() {
connecting = false;
});
connecting = true;
}
}

@@ -170,3 +177,3 @@ }

var self = this;
if (this.currentState.plugged.length > 0) {

@@ -173,0 +180,0 @@ callback(null, this.currentState);

2

lib/deviceloader.js

@@ -97,3 +97,3 @@ var EventEmitter2 = require('eventemitter2').EventEmitter2,

// if (!self.isRunning) return;
// process.nextTick(function() {

@@ -100,0 +100,0 @@ // self.trigger(function() {

@@ -33,3 +33,10 @@ var sp = require("serialport"),

var devices = _.map(resPorts, function(p) {
return new self.Device(p.comName);
var found = _.find(self.oldDevices, function(dev) {
return dev.get('portName') === p.comName;
});
if (found) {
return found;
} else {
return new self.Device(p.comName);
}
}) || [];

@@ -36,0 +43,0 @@

{
"name": "devicestack",
"version": "1.3.2",
"version": "1.3.3",
"description": "This module helps you to represent a device and its protocol.",

@@ -8,3 +8,3 @@ "private": false,

"engines": {
"node": ">=0.8.0",
"node": ">=0.8.x",
"npm": ">=1.1.x"

@@ -24,3 +24,3 @@ },

"optionalDependencies": {
"serialport": "https://github.com/KABA-CCEAC/node-serialport.git/node-serialport/tarball/master"
"serialport": "https://github.com/KABA-CCEAC/node-serialport/tarball/master"
},

@@ -27,0 +27,0 @@ "devDependencies": {

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc