fix error parsing 🐛

This commit is contained in:
Jannis R 2018-12-06 11:31:38 +01:00
parent e7efcb5405
commit b809281d0e
No known key found for this signature in database
GPG key ID: 0FE83946296A88A5

View file

@ -88,7 +88,7 @@ const request = (profile, userAgent, opt, data) => {
.then((b) => { .then((b) => {
if (DEBUG) console.error(JSON.stringify(b)) if (DEBUG) console.error(JSON.stringify(b))
if (b.err) { if (b.err && b.err !== 'OK') {
err.message = b.err err.message = b.err
throw err throw err
} }