From f2efe5a2ddf9e10a83bf24da2af744061b2ae597 Mon Sep 17 00:00:00 2001 From: Philipp Bauer <36240461+BauerPh@users.noreply.github.com> Date: Sun, 15 Oct 2023 03:56:38 +0200 Subject: [PATCH] fix: sql-template-strings/tag compatibility (#2238) --- lib/connection.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/connection.js b/lib/connection.js index b9f01a4cf4..12c0b8bb12 100644 --- a/lib/connection.js +++ b/lib/connection.js @@ -622,7 +622,8 @@ class Connection extends EventEmitter { // execute(options, cb) options = { ...options, - ...sql + ...sql, + sql: sql.sql }; if (typeof values === 'function') { cb = values; @@ -911,7 +912,8 @@ class Connection extends EventEmitter { // query(options, cb) options = { ...options, - ...sql + ...sql, + sql: sql.sql }; if (typeof values === 'function') { cb = values;