mssql 10.0.1 → 10.0.3

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
@@ -17,7 +17,7 @@ Supported TDS drivers:
17
17
  ```javascript
18
18
  const sql = require('mssql')
19
19
 
20
- async () => {
20
+ (async () => {
21
21
  try {
22
22
  // make sure that any items are correctly URL encoded in the connection string
23
23
  await sql.connect('Server=localhost,1433;Database=database;User Id=username;Password=password;Encrypt=true')
@@ -26,7 +26,7 @@ async () => {
26
26
  } catch (err) {
27
27
  // ... error checks
28
28
  }
29
- }
29
+ })()
30
30
  ```
31
31
 
32
32
  If you're on Windows Azure, add `?encrypt=true` to your connection string. See [docs](#configuration) to learn more.
@@ -39,6 +39,7 @@ Assuming you have set the appropriate environment variables, you can construct a
39
39
 
40
40
  ```javascript
41
41
  const sql = require('mssql')
42
+
42
43
  const sqlConfig = {
43
44
  user: process.env.DB_USER,
44
45
  password: process.env.DB_PWD,
@@ -55,7 +56,7 @@ const sqlConfig = {
55
56
  }
56
57
  }
57
58
 
58
- async () => {
59
+ (async () => {
59
60
  try {
60
61
  // make sure that any items are correctly URL encoded in the connection string
61
62
  await sql.connect(sqlConfig)
@@ -64,7 +65,7 @@ async () => {
64
65
  } catch (err) {
65
66
  // ... error checks
66
67
  }
67
- }
68
+ })()
68
69
  ```
69
70
 
70
71
  ## Documentation
@@ -363,7 +363,7 @@ class ConnectionPool extends EventEmitter {
363
363
  */
364
364
 
365
365
  acquire (requester, callback) {
366
- const acquirePromise = shared.Promise.resolve(this._acquire().promise).catch(err => {
366
+ const acquirePromise = shared.Promise.resolve(this._acquire()).catch(err => {
367
367
  this.emit('error', err)
368
368
  throw err
369
369
  })
@@ -382,7 +382,7 @@ class ConnectionPool extends EventEmitter {
382
382
  return shared.Promise.reject(new ConnectionError('Connection is closing', 'ENOTOPEN'))
383
383
  }
384
384
 
385
- return this.pool.acquire()
385
+ return this.pool.acquire().promise
386
386
  }
387
387
 
388
388
  /**
package/lib/datatypes.js CHANGED
@@ -160,6 +160,7 @@ module.exports.cast = (value, type, options) => {
160
160
  return `N'${value.replace(/'/g, '\'\'')}'`
161
161
 
162
162
  case 'number':
163
+ case 'bigint':
163
164
  return value
164
165
 
165
166
  case 'boolean':
package/package.json CHANGED
@@ -21,8 +21,9 @@
21
21
  "azure",
22
22
  "node-mssql"
23
23
  ],
24
- "version": "10.0.1",
24
+ "version": "10.0.3",
25
25
  "main": "index.js",
26
+ "type": "commonjs",
26
27
  "repository": "github:tediousjs/node-mssql",
27
28
  "license": "MIT",
28
29
  "dependencies": {
@@ -31,21 +32,21 @@
31
32
  "debug": "^4.3.3",
32
33
  "rfdc": "^1.3.0",
33
34
  "tarn": "^3.0.2",
34
- "tedious": "^16.4.0"
35
+ "tedious": "^18.2.1"
35
36
  },
36
37
  "devDependencies": {
37
- "@commitlint/cli": "^17.6.6",
38
- "@commitlint/config-conventional": "^17.6.6",
39
- "@semantic-release/commit-analyzer": "^10.0.1",
40
- "@semantic-release/github": "^9.0.3",
41
- "@semantic-release/npm": "^10.0.4",
42
- "@semantic-release/release-notes-generator": "^11.0.4",
38
+ "@commitlint/cli": "^19.0.3",
39
+ "@commitlint/config-conventional": "^19.0.3",
40
+ "@semantic-release/commit-analyzer": "^13.0.0",
41
+ "@semantic-release/github": "^10.0.2",
42
+ "@semantic-release/npm": "^12.0.0",
43
+ "@semantic-release/release-notes-generator": "^14.0.0",
43
44
  "mocha": "^10.0.0",
44
- "semantic-release": "^21.0.7",
45
+ "semantic-release": "^24.0.0",
45
46
  "standard": "^17.0.0"
46
47
  },
47
48
  "engines": {
48
- "node": ">=14"
49
+ "node": ">=18"
49
50
  },
50
51
  "files": [
51
52
  "lib/",