@imenam/database-mcp 1.0.13 → 1.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/db.js +1 -1
- package/package.json +1 -1
package/dist/db.js
CHANGED
|
@@ -209,7 +209,7 @@ class HttpProxyAdapter {
|
|
|
209
209
|
body: JSON.stringify({ sql, params }),
|
|
210
210
|
});
|
|
211
211
|
const json = await res.json();
|
|
212
|
-
if (!res.ok) {
|
|
212
|
+
if (!res.ok || json.error) {
|
|
213
213
|
throw new Error(json.error ?? `HTTP ${res.status}`);
|
|
214
214
|
}
|
|
215
215
|
return json.data ?? [];
|