mirror of
https://github.com/node-red/node-red-nodes.git
synced 2023-10-10 13:36:58 +02:00
Mysql - Only call done if it exists.
This commit is contained in:
parent
290b2ea790
commit
799eee3873
@ -159,7 +159,7 @@ module.exports = function(RED) {
|
||||
status = {fill:"green",shape:"dot",text:"OK"};
|
||||
node.status(status);
|
||||
}
|
||||
done();
|
||||
if (done) { done(); }
|
||||
// if (node.mydbConfig.pool._freeConnections.indexOf(node.mydbConfig.connection) === -1) {
|
||||
// node.mydbConfig.connection.release();
|
||||
// }
|
||||
@ -172,7 +172,7 @@ module.exports = function(RED) {
|
||||
else {
|
||||
node.error("Database not connected",msg);
|
||||
status = {fill:"red",shape:"ring",text:"not yet connected"};
|
||||
done();
|
||||
if (done) { done(); }
|
||||
}
|
||||
if (!busy) {
|
||||
busy = true;
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "node-red-node-mysql",
|
||||
"version": "0.2.0",
|
||||
"version": "0.2.1",
|
||||
"description": "A Node-RED node to read and write to a MySQL database",
|
||||
"dependencies": {
|
||||
"mysql": "^2.18.1"
|
||||
|
Loading…
Reference in New Issue
Block a user