Closed codymwalker closed 8 years ago
Spotted this one this afternoon.
Need to have a discussion about this functionality. I don't think we want to expose the node runtime objects to allow their functions to be called like this. I over looked that the swagger node did this when I made some of the changesin .12.
Gotcha.
Had actually just sent you an email about his as well. I just wanted to follow up and make sure that it was intentional. If you don't want those functions exposed, I can remove the status calls from this node, as they'll always be external to the actual node.
Yeah - allowing a node direct access to another node's functions is just asking for trouble and will tie our hands in the future.
I think we should remove these calls - I'm happy to sort that out tomorrow unless you get a PR in before then.
PR is #32. Removed the nls for the status messages as well.
results in
TypeError: Object #<Object> has no method 'status' at C:\Users\cody\Downloads\node-red-0.12.0\node-red-0.12.0\node_modules\node-red-node-swagger\swagger\swagger.js:126:26