mirror of https://github.com/bastienwirtz/homer
force response to text if not json
Without that I'm getting Version "[object Response]" on the smart card from an api that returns text/plain. See #847 - add Docuseal (requires text/plain support or hack)main
parent
2f1cbe7328
commit
aba3b5eed7
|
@ -56,7 +56,7 @@ export default {
|
|||
throw new Error(`Ping: target not available (${response.status} error)`);
|
||||
}
|
||||
|
||||
return json ? response.json() : response;
|
||||
return json ? response.json() : response.text();
|
||||
});
|
||||
},
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue