removd active
--- a/onvif/snapshot.html
+++ b/onvif/snapshot.html
@@ -29,8 +29,7 @@
name: {value: ""},
url: {value: "", required: true},
username: {value: ""},
- password: {value: ""},
- active: {value: true, validate: RED.validators.boolean()}
+ password: {value: ""}
},
inputs: 1,
outputs: 1,
--- a/onvif/snapshot.js
+++ b/onvif/snapshot.js
@@ -5,11 +5,6 @@
function snapshot(config) {
RED.nodes.createNode(this, config);
let node = this;
- let msg = {
- name: config.name,
- url: config.url,
- error: false
- };
node.on("input", function (msg) {
try {
@@ -24,9 +19,6 @@
if(_msg.hasOwnProperty("password")) {
msg.password = _msg.password;
}
- if(_msg.hasOwnProperty("active")) {
- msg.active = _msg.active;
- }
}
}
catch (ex) {}
@@ -34,7 +26,6 @@
config.url = msg.url || config.url;
config.username = msg.username || config.username;
config.password = msg.password || config.password;
- node.active = config.active = msg.active || config.active;
if(msg.hasOwnProperty("payload")) {
msg._payload = msg.payload;
@@ -52,8 +43,6 @@
RED.nodes.registerType("ONVIF Snapshot", snapshot);
function run(msg, node, config) {
- if (node.active == false) return;
-
let onvifInstance = new onvif.OnvifDevice({
xaddr: config.url,
user : config.username,