@beamnetwork/eco-prime-trust-api
Advanced tools
Comparing version 1.0.17 to 1.0.18
@@ -117,7 +117,15 @@ "use strict"; | ||
} | ||
var finalErrors; | ||
var error = ex.error; | ||
if (error) { | ||
finalErrors = [error]; | ||
} | ||
else { | ||
finalErrors = [{ | ||
message: ex.message || ex, | ||
}]; | ||
} | ||
return { | ||
status: -1, | ||
errors: [{ | ||
message: ex.error || ex, | ||
}] | ||
errors: finalErrors, | ||
}; | ||
@@ -124,0 +132,0 @@ }; |
{ | ||
"name": "@beamnetwork/eco-prime-trust-api", | ||
"private": false, | ||
"version": "1.0.17", | ||
"version": "1.0.18", | ||
"description": "Eco Prime Trust API TypeScript Implementation", | ||
@@ -6,0 +6,0 @@ "main": "lib/index.js", |
@@ -67,9 +67,18 @@ import axios, { AxiosInstance } from 'axios' | ||
let finalErrors: any[] | ||
const { error } = ex | ||
if (error) { | ||
finalErrors = [error] | ||
} else { | ||
finalErrors = [{ | ||
message: ex.message || ex, | ||
}] | ||
} | ||
return { | ||
status: -1, | ||
errors: [{ | ||
message: ex.error || ex, | ||
}] | ||
errors: finalErrors, | ||
} | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
522573
5848