@bdkinc/knex-ibmi 0.0.13 → 0.0.15

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/README.md CHANGED
@@ -108,7 +108,7 @@ try {
108
108
  or as Typescript
109
109
 
110
110
  ```typescript
111
- import knex from "knex";
111
+ import { knex } from "knex";
112
112
  import { Db2Dialect, DB2Config } from "knex-ibmi";
113
113
 
114
114
  const config: DB2Config = {
package/dist/index.js CHANGED
@@ -161,19 +161,17 @@ var ibmi_columncompiler_default = IBMiColumnCompiler;
161
161
  // src/execution/ibmi-transaction.ts
162
162
  var import_transaction = __toESM(require("knex/lib/execution/transaction"));
163
163
  var IBMiTransaction = class extends import_transaction.default {
164
- async begin(conn) {
165
- const connection = await conn.connect();
164
+ async begin(connection) {
166
165
  await connection.beginTransaction();
167
166
  return connection;
168
167
  }
169
- async rollback(conn) {
170
- const connection = await conn.connect();
168
+ async rollback(connection) {
171
169
  await connection.rollback();
172
170
  return connection;
173
171
  }
174
- async commit(conn) {
175
- await conn.commit();
176
- return conn;
172
+ async commit(connection) {
173
+ await connection.commit();
174
+ return connection;
177
175
  }
178
176
  };
179
177
  var ibmi_transaction_default = IBMiTransaction;
package/dist/index.mjs CHANGED
@@ -126,19 +126,17 @@ var ibmi_columncompiler_default = IBMiColumnCompiler;
126
126
  // src/execution/ibmi-transaction.ts
127
127
  import Transaction from "knex/lib/execution/transaction";
128
128
  var IBMiTransaction = class extends Transaction {
129
- async begin(conn) {
130
- const connection = await conn.connect();
129
+ async begin(connection) {
131
130
  await connection.beginTransaction();
132
131
  return connection;
133
132
  }
134
- async rollback(conn) {
135
- const connection = await conn.connect();
133
+ async rollback(connection) {
136
134
  await connection.rollback();
137
135
  return connection;
138
136
  }
139
- async commit(conn) {
140
- await conn.commit();
141
- return conn;
137
+ async commit(connection) {
138
+ await connection.commit();
139
+ return connection;
142
140
  }
143
141
  };
144
142
  var ibmi_transaction_default = IBMiTransaction;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bdkinc/knex-ibmi",
3
- "version": "0.0.13",
3
+ "version": "0.0.15",
4
4
  "description": "Knex dialect for IBMi",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -1,21 +1,19 @@
1
1
  import Transaction from "knex/lib/execution/transaction";
2
2
 
3
3
  class IBMiTransaction extends Transaction {
4
- async begin(conn) {
5
- const connection = await conn.connect();
4
+ async begin(connection) {
6
5
  await connection.beginTransaction();
7
6
  return connection;
8
7
  }
9
8
 
10
- async rollback(conn) {
11
- const connection = await conn.connect();
9
+ async rollback(connection) {
12
10
  await connection.rollback();
13
11
  return connection;
14
12
  }
15
13
 
16
- async commit(conn) {
17
- await conn.commit();
18
- return conn;
14
+ async commit(connection) {
15
+ await connection.commit();
16
+ return connection;
19
17
  }
20
18
  }
21
19