mysql2 3.23.3 → 3.23.4-canary.8b1f829

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": "mysql2",
3
- "version": "3.23.3",
3
+ "version": "3.23.4-canary.8b1f829",
4
4
  "description": "fast mysql driver. Implements core protocol, prepared statements, ssl and compression in native JS",
5
5
  "main": "index.js",
6
6
  "typings": "typings/mysql/index",
@@ -70,6 +70,16 @@ declare class Pool extends QueryableBase(ExecutableBase(EventEmitter)) {
70
70
 
71
71
  unprepare(sql: string): PrepareStatementInfo;
72
72
 
73
+ /**
74
+ * Escaping helpers, available on a `Pool` just like on a `Connection`.
75
+ */
76
+ escape(value: any): string;
77
+
78
+ escapeId(value: string): string;
79
+ escapeId(values: string[]): string;
80
+
81
+ format(sql: string, values?: any | any[] | { [param: string]: any }): string;
82
+
73
83
  promise(promiseImpl?: PromiseConstructor): PromisePool;
74
84
 
75
85
  config: PoolOptions;
@@ -1,11 +1,16 @@
1
1
  import { Connection } from './Connection.js';
2
- import { Pool as PromisePool } from '../../../promise.js';
2
+ import { PoolConnection as PromisePoolConnection } from '../../../promise.js';
3
3
 
4
4
  declare class PoolConnection extends Connection {
5
5
  connection: Connection;
6
6
  release(): void;
7
7
  [Symbol.dispose](): void;
8
- promise(promiseImpl?: PromiseConstructor): PromisePool;
8
+ /**
9
+ * Returns a promise-based wrapper around this pooled connection.
10
+ *
11
+ * Note: this resolves to a `PoolConnection` from `mysql2/promise`, not to a `Pool`.
12
+ */
13
+ promise(promiseImpl?: PromiseConstructor): PromisePoolConnection;
9
14
  }
10
15
 
11
16
  export { PoolConnection };