diff --git a/actions/user.js b/actions/user.js index c8f297fe2..88bece40f 100644 --- a/actions/user.js +++ b/actions/user.js @@ -361,7 +361,7 @@ function getUserIdentityByAuth0Id(api, connection, next) { function (cb) { try { var splits = auth0id.split('|'); - if (splits[0] === 'ad') { + if (splits[0] === 'ad' || splits[0] === 'auth0') { cb(null, [{ user_id: Number(splits[1]) }]); } else { api.helper.getProviderId(splits[0], function (err, provider) { diff --git a/config/logger.js b/config/logger.js index 5d4991f1a..0812c59c3 100644 --- a/config/logger.js +++ b/config/logger.js @@ -12,7 +12,7 @@ exports.default = { logger.transports.push(function (api, winston) { return new (winston.transports.Console)({ colorize: true, - level: 'debug', + level: 'info', timestamp: api.utils.sqlDateTime, json: false }); @@ -31,7 +31,7 @@ exports.default = { logger.transports.push(function (api, winston) { return new (winston.transports.File)({ filename: api.config.general.paths.log[0] + '/actionhero-worker.log', - level: 'debug', + level: 'info', colorize: true, timestamp: api.utils.sqlDateTime, json: false diff --git a/initializers/dataAccess.js b/initializers/dataAccess.js index 33ce3bdfe..9849555db 100644 --- a/initializers/dataAccess.js +++ b/initializers/dataAccess.js @@ -309,10 +309,13 @@ exports.dataAccess = function (api, next) { return; } - sql = queries[queryName].sql; + sql = queries[queryName].sql; if (!isSafeToUseJavaBridge(sql) || !api.helper.readTransaction) { connection = connectionMap[queries[queryName].db]; + api.log("######### MD #########", "info"); + api.log(JSON.stringify(connectionMap), "info"); + api.log(queryName, "info"); error = helper.checkObject(connection, "connection"); } @@ -374,4 +377,4 @@ exports.dataAccess = function (api, next) { } }; next(); -}; \ No newline at end of file +}; diff --git a/initializers/helper.js b/initializers/helper.js index 2acc131d8..2e53f1cc6 100644 --- a/initializers/helper.js +++ b/initializers/helper.js @@ -1219,7 +1219,7 @@ helper.getProviderId = function (provider, callback) { if (provider.startsWith("salesforce")) { providerId = helper.socialProviders.salesforce; } - if (provider.startsWith("ad")) { + if (provider.startsWith("ad") || provider.startsWith("auth0")) { providerId = helper.socialProviders.ad; } if (providerId) {