Update db.js

This commit is contained in:
Rob Hedgpeth
2021-05-27 07:32:56 -05:00
committed by GitHub
parent 080b1e2964
commit 12f2482945

View File

@ -13,13 +13,7 @@ var pool =
// Expose a method to establish connection with MariaDB SkySQL
module.exports={
getConnection: function(){
return new Promise(function(resolve,reject){
pool.getConnection().then(function(connection){
resolve(connection);
}).catch(function(error){
reject(error);
});
});
getConnection: async function(){
return pool.getConnection();
}
}
}