yarn.lock and libtextsecure.js catchup
This commit is contained in:
parent
0e328f3911
commit
be2d4535a8
2 changed files with 342 additions and 282 deletions
|
@ -37500,30 +37500,9 @@ var TextSecureServer = (function() {
|
|||
}
|
||||
window.nodeFetch(url, fetchOptions).then(function(response) {
|
||||
var resultPromise;
|
||||
<<<<<<< HEAD
|
||||
if (options.responseType === 'json'
|
||||
&& response.headers.get('Content-Type') === 'application/json') {
|
||||
resultPromise = response.json();
|
||||
||||||| merged common ancestors
|
||||
if (options.responseType === 'json') {
|
||||
resultPromise = response.json();
|
||||
} else if (!options.responseType || options.responseType === 'text') {
|
||||
resultPromise = response.text();
|
||||
=======
|
||||
if (options.responseType === 'json') {
|
||||
resultPromise = response.json().catch(function(error) {
|
||||
// If the response was otherwise successful, a JSON.parse() failure really
|
||||
// is a problem. But the Signal server does return HTML in error cases
|
||||
// when we requested JSON, sadly.
|
||||
if (0 <= response.status && response.status < 400) {
|
||||
throw error;
|
||||
}
|
||||
|
||||
return null;
|
||||
})
|
||||
} else if (!options.responseType || options.responseType === 'text') {
|
||||
resultPromise = response.text();
|
||||
>>>>>>> master
|
||||
} else if (options.responseType === 'arraybuffer') {
|
||||
resultPromise = response.buffer();
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue