Remove null-conditional operator
This commit is contained in:
parent
dbd6487b0b
commit
beea6675cb
@ -35,7 +35,7 @@ async function apiRequest(
|
|||||||
body: data == undefined ? null : JSON.stringify(data),
|
body: data == undefined ? null : JSON.stringify(data),
|
||||||
});
|
});
|
||||||
|
|
||||||
const reviver = options?.jsonReviver;
|
const reviver = options == undefined ? undefined : options.jsonReviver;
|
||||||
if (reviver != undefined) {
|
if (reviver != undefined) {
|
||||||
return JSON.parse(await res.text(), reviver);
|
return JSON.parse(await res.text(), reviver);
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user