From 67742bca3adbe28219b3be0aa4eaf0be23e7c16a Mon Sep 17 00:00:00 2001 From: Nikola Ubavic <53820106+ubavic@users.noreply.github.com> Date: Mon, 29 Nov 2021 14:02:46 +0100 Subject: [PATCH] fix: use spex batch --- lib/pairing.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/pairing.js b/lib/pairing.js index d919300d..b848b859 100644 --- a/lib/pairing.js +++ b/lib/pairing.js @@ -35,7 +35,7 @@ function unpair (deviceId) { const q2 = t.none(`DELETE FROM machine_pings WHERE device_id=$1`, [deviceId]) const q3 = t.none(`DELETE FROM machine_network_heartbeat WHERE device_id=$1`, [deviceId]) const q4 = t.none(`DELETE FROM machine_network_performance WHERE device_id=$1`, [deviceId]) - return Promise.all([q1, q2, q3, q4]) + return t.batch([q1, q2, q3, q4]) }) ) }