metal-orm 1.0.22 → 1.0.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "metal-orm",
3
- "version": "1.0.22",
3
+ "version": "1.0.23",
4
4
  "type": "module",
5
5
  "types": "./dist/index.d.ts",
6
6
  "bin": {
@@ -571,6 +571,8 @@ const loadDriver = async (dialect, url, dbPath) => {
571
571
  };
572
572
  connection.once('connect', onConnect);
573
573
  connection.once('error', onError);
574
+ // Tedious requires an explicit connect() call to start the handshake.
575
+ connection.connect();
574
576
  });
575
577
 
576
578
  const execQuery = (sql, params) =>
@@ -578,7 +580,7 @@ const loadDriver = async (dialect, url, dbPath) => {
578
580
  const rows = [];
579
581
  const request = new Request(sql, err => {
580
582
  if (err) return reject(err);
581
- resolve(rows);
583
+ resolve({ recordset: rows });
582
584
  });
583
585
  request.on('row', columns => {
584
586
  const row = {};