mirror of
https://github.com/node-red/node-red-nodes.git
synced 2025-03-01 10:37:43 +00:00
slightly nicer jscs style updates to several nodes
again not pushed to npm - still just whitespace.
This commit is contained in:
@@ -43,17 +43,17 @@ module.exports = function(RED) {
|
||||
else { http = require("http"); }
|
||||
this.on("input", function(msg) {
|
||||
this.url = this.baseurl + '/input/post.json?';
|
||||
if (msg.payload.indexOf(':') > -1){
|
||||
if (msg.payload.indexOf(':') > -1) {
|
||||
this.url += 'json={' + msg.payload + '}';
|
||||
} else {
|
||||
this.url += 'csv='+msg.payload;
|
||||
}
|
||||
this.url += '&apikey='+this.apikey;
|
||||
var nodegroup = this.nodegroup || msg.nodegroup;
|
||||
if (nodegroup !== ""){
|
||||
if (nodegroup !== "") {
|
||||
this.url += '&node=' + nodegroup;
|
||||
}
|
||||
if (typeof msg.time !== 'undefined'){
|
||||
if (typeof msg.time !== 'undefined') {
|
||||
this.url += '&time=' + msg.time;
|
||||
}
|
||||
node.log("[emoncms] "+this.url);
|
||||
|
Reference in New Issue
Block a user