Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@minatojs/driver-mysql

Package Overview
Dependencies
Maintainers
2
Versions
58
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@minatojs/driver-mysql - npm Package Compare versions

Comparing version 2.5.1 to 2.5.2

2

lib/index.d.ts

@@ -43,3 +43,3 @@ import type { Pool, PoolConfig } from 'mysql';

_formatValues: (table: string, data: object, keys: readonly string[]) => string;
query<T = any>(sql: string): Promise<T>;
query<T = any>(sql: string, debug?: boolean): Promise<T>;
queue<T = any>(sql: string, values?: any): Promise<T>;

@@ -46,0 +46,0 @@ private _flushTasks;

@@ -353,9 +353,11 @@ "use strict";

};
query(sql) {
query(sql, debug = true) {
const error = new Error();
return new Promise((resolve, reject) => {
if (debug)
logger.debug("> %s", sql);
this.pool.query(sql, (err, results) => {
if (!err)
return resolve(results);
logger.warn(sql);
logger.warn("> %s", sql);
if (err["code"] === "ER_DUP_ENTRY") {

@@ -371,3 +373,2 @@ err = new import_core.RuntimeError("duplicate-entry", err.message);

sql = (0, import_mysql.format)(sql, values);
logger.debug("> %s", sql);
if (!this.config.multipleStatements) {

@@ -387,3 +388,3 @@ return this.query(sql);

try {
let results = await this.query(tasks.map((task) => task.sql).join("; "));
let results = await this.query(tasks.map((task) => task.sql).join("; "), false);
if (tasks.length === 1)

@@ -390,0 +391,0 @@ results = [results];

{
"name": "@minatojs/driver-mysql",
"version": "2.5.1",
"version": "2.5.2",
"description": "MySQL Driver for Minato",

@@ -38,4 +38,4 @@ "main": "lib/index.js",

"cosmokit": "^1.4.5",
"reggol": "^1.5.1"
"reggol": "^1.5.2"
}
}

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc