1
1
# generated by patch-package 6.4.14
2
2
#
3
3
# declared package:
4
- # mysql2: 3.5.1
4
+ # mysql2: 3.10.2
5
5
#
6
6
diff --git a/node_modules/mysql2/lib/connection.js b/node_modules/mysql2/lib/connection.js
7
- index d6ad7a4..ceac670 100644
7
+ index 113fc7d..3a997a4 100644
8
8
--- a/node_modules/mysql2/lib/connection.js
9
9
+++ b/node_modules/mysql2/lib/connection.js
10
10
@@ -32,7 +32,7 @@ const CharsetToEncoding = require('./constants/charset_encodings.js');
@@ -16,7 +16,7 @@ index d6ad7a4..ceac670 100644
16
16
17
17
class Connection extends EventEmitter {
18
18
constructor(opts) {
19
- @@ -521 ,7 +521 ,7 @@ class Connection extends EventEmitter {
19
+ @@ -524 ,7 +524 ,7 @@ class Connection extends EventEmitter {
20
20
sql: sql,
21
21
values: values
22
22
};
@@ -25,7 +25,7 @@ index d6ad7a4..ceac670 100644
25
25
return SqlString.format(
26
26
opts.sql,
27
27
opts.values,
28
- @@ -543 ,20 +543 ,20 @@ class Connection extends EventEmitter {
28
+ @@ -546 ,20 +546 ,20 @@ class Connection extends EventEmitter {
29
29
}
30
30
31
31
_resolveNamedPlaceholders(options) {
@@ -60,7 +60,7 @@ index d6ad7a4..ceac670 100644
60
60
}
61
61
62
62
query(sql, values, cb) {
63
- @@ -566 ,7 +566 ,7 @@ class Connection extends EventEmitter {
63
+ @@ -569 ,7 +569 ,7 @@ class Connection extends EventEmitter {
64
64
} else {
65
65
cmdQuery = Connection.createQuery(sql, values, cb, this.config);
66
66
}
@@ -69,7 +69,7 @@ index d6ad7a4..ceac670 100644
69
69
const rawSql = this.format(cmdQuery.sql, cmdQuery.values !== undefined ? cmdQuery.values : []);
70
70
cmdQuery.sql = rawSql;
71
71
return this.addCommand(cmdQuery);
72
- @@ -634 ,26 +634 ,27 @@ class Connection extends EventEmitter {
72
+ @@ -644 ,26 +644 ,27 @@ class Connection extends EventEmitter {
73
73
options.sql = sql;
74
74
options.values = values;
75
75
}
@@ -128,10 +128,10 @@ index daf1df9..0862ce1 100644
128
128
case 'number':
129
129
type = Types.DOUBLE;
130
130
diff --git a/node_modules/mysql2/lib/parsers/binary_parser.js b/node_modules/mysql2/lib/parsers/binary_parser.js
131
- index bbd2959..80ab00d 100644
131
+ index c80bf96..da453ca 100644
132
132
--- a/node_modules/mysql2/lib/parsers/binary_parser.js
133
133
+++ b/node_modules/mysql2/lib/parsers/binary_parser.js
134
- @@ -72 ,7 +72 ,7 @@ function readCodeFor(field, config, options, fieldNum) {
134
+ @@ -75 ,7 +75 ,7 @@ function readCodeFor(field, config, options, fieldNum) {
135
135
136
136
default:
137
137
if (field.characterSet === Charsets.BINARY) {
@@ -140,29 +140,35 @@ index bbd2959..80ab00d 100644
140
140
}
141
141
return `packet.readLengthCodedString(fields[${fieldNum}].encoding)`;
142
142
}
143
+ @@ -92,6 +92,7 @@ function compile(fields, options, config) {
144
+ db: field.schema,
145
+ table: field.table,
146
+ name: field.name,
147
+ + charset: field.characterSet,
148
+ string: function (encoding = field.encoding) {
149
+ if (field.columnType === Types.JSON && encoding === field.encoding) {
150
+ // Since for JSON columns mysql always returns charset 63 (BINARY),
143
151
diff --git a/node_modules/mysql2/lib/parsers/text_parser.js b/node_modules/mysql2/lib/parsers/text_parser.js
144
- index 49a128c..7eafb2c 100644
152
+ index f66a185..55c8b63 100644
145
153
--- a/node_modules/mysql2/lib/parsers/text_parser.js
146
154
+++ b/node_modules/mysql2/lib/parsers/text_parser.js
147
- @@ -85 ,6 +85 ,7 @@ function compile(fields, options, config) {
155
+ @@ -88 ,6 +88 ,7 @@ function compile(fields, options, config) {
148
156
db: field.schema,
149
157
table: field.table,
150
158
name: field.name,
151
159
+ charset: field.characterSet,
152
- string: function(encoding = field.encoding) {
160
+ string: function (encoding = field.encoding) {
153
161
if (field.columnType === Types.JSON && encoding === field.encoding) {
154
162
// Since for JSON columns mysql always returns charset 63 (BINARY),
155
- diff --git a/node_modules/mysql2/lib/pool.js b/node_modules/mysql2/lib/pool.js
156
- index db54a7a..f104061 100644
157
- --- a/node_modules/mysql2/lib/pool.js
158
- +++ b/node_modules/mysql2/lib/pool.js
159
- @@ -155,7 +155,8 @@ class Pool extends EventEmitter {
160
- });
161
- } catch (e) {
162
- conn.release();
163
- - throw e;
164
- + // throw e;
165
- + return cb(e);
166
- }
167
- });
168
- return cmdQuery;
163
+ diff --git a/node_modules/mysql2/typings/mysql/lib/parsers/typeCast.d.ts b/node_modules/mysql2/typings/mysql/lib/parsers/typeCast.d.ts
164
+ index 65bfaa8..52ab677 100644
165
+ --- a/node_modules/mysql2/typings/mysql/lib/parsers/typeCast.d.ts
166
+ +++ b/node_modules/mysql2/typings/mysql/lib/parsers/typeCast.d.ts
167
+ @@ -43,6 +43,7 @@ export type Field = Type & {
168
+ db: string;
169
+ table: string;
170
+ name: string;
171
+ + charset: number;
172
+ string: (encoding?: BufferEncoding | string | undefined) => string | null;
173
+ buffer: () => Buffer | null;
174
+ geometry: () => Geometry | Geometry[] | null;
0 commit comments