@collabland/common
Advanced tools
Comparing version 0.23.1 to 0.23.2
@@ -11,2 +11,3 @@ "use strict"; | ||
const http_errors_1 = (0, tslib_1.__importDefault)(require("http-errors")); | ||
const _1 = require("."); | ||
const debug_1 = require("./debug"); | ||
@@ -125,3 +126,4 @@ var http_errors_2 = require("http-errors"); | ||
if (body.error) { | ||
const err = new http_errors_1.default.BadRequest(`JSONRPC Error - ${url}`); | ||
const errorObj = (0, _1.stringify)(body.error); | ||
const err = new http_errors_1.default.BadRequest(`JSONRPC Error - ${url}: ${errorObj}`); | ||
err.details = body.error; | ||
@@ -128,0 +130,0 @@ throw err; |
{ | ||
"name": "@collabland/common", | ||
"version": "0.23.1", | ||
"version": "0.23.2", | ||
"description": "CollabLand common utilities", | ||
@@ -62,3 +62,3 @@ "main": "dist/index.js", | ||
"author": "Abridged, Inc.", | ||
"gitHead": "154108d67dcb9f75a4f884055a075e3c3a91933b" | ||
"gitHead": "e5ad9ea01438af9dc8fcb8a2690cb9a27b052fde" | ||
} |
@@ -8,2 +8,3 @@ // Copyright Abridged, Inc. 2021. All Rights Reserved. | ||
import HttpErrors from 'http-errors'; | ||
import {stringify} from '.'; | ||
import {debugFactory} from './debug'; | ||
@@ -182,3 +183,6 @@ | ||
if (body.error) { | ||
const err = new HttpErrors.BadRequest(`JSONRPC Error - ${url}`); | ||
const errorObj = stringify(body.error); | ||
const err = new HttpErrors.BadRequest( | ||
`JSONRPC Error - ${url}: ${errorObj}`, | ||
); | ||
err.details = body.error; | ||
@@ -185,0 +189,0 @@ throw err; |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
101535
2486