diff --git a/package.json b/package.json index cc4d93e4..d6b230f2 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "antares", "productName": "Antares", - "version": "0.0.2-alpha", + "version": "0.0.3-alpha", "description": "A cross-platform easy to use SQL client.", "license": "MIT", "repository": "https://github.com/EStarium/antares.git", diff --git a/src/main/libs/AntaresConnector.js b/src/main/libs/AntaresConnector.js index 189c0056..3d0e0f3f 100644 --- a/src/main/libs/AntaresConnector.js +++ b/src/main/libs/AntaresConnector.js @@ -20,6 +20,7 @@ export class AntaresConnector { this._params = args.params; this._poolSize = args.poolSize || false; this._connection = null; + this._logger = args.logger || console.log; this._queryDefaults = { schema: '', @@ -247,7 +248,7 @@ export class AntaresConnector { * @memberof AntaresConnector */ async raw (sql) { - if (process.env.NODE_ENV === 'development') console.log(sql); + if (process.env.NODE_ENV === 'development') this._logger(sql); switch (this._client) { // TODO: uniform fields with every client type, needed table name and fields array case 'maria':