diff --git a/lib/mysql.js b/lib/mysql.js index 32c1aaa..7fabe86 100644 --- a/lib/mysql.js +++ b/lib/mysql.js @@ -22,9 +22,9 @@ exports.initialize = function initializeDataSource(dataSource, callback) { s.timezone = (s.timezone || 'local'); dataSource.client = mysql.createConnection({ - host: s.host || 'localhost', + host: s.host || s.hostname || 'localhost', port: s.port || 3306, - user: s.username, + user: s.username || s.user, password: s.password, timezone: s.timezone, debug: s.debug,