Details
-
Task
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
None
-
None
Description
see https://github.com/mariadb-corporation/mariadb-connector-nodejs/issues/217
Actual implementation return meta as enumerable property of resultset.
example:
const res = await connection.query('select * from animals'); |
console.log(res):
|
// [
|
// { id: 1, name: 'sea lions' },
|
// { id: 2, name: 'bird' },
|
// meta: [ ... ]
|
// ]
|
|
A better solution would be to still have meta property, but nonenumerable:
const res = await connection.query('select * from animals'); |
console.log(res):
|
// res : [
|
// { id: 1, name: 'sea lions' },
|
// { id: 2, name: 'bird' }
|
// ]
|
const meta = res.meta; |
// meta: [ ... ]
|
|