forked from extern/bruno
Merge pull request #1055 from adarshlilha/bugfix/boolean-falsy-response-missing
fix(#1035): fix falsy check of response
This commit is contained in:
commit
fad71e936c
@ -11,7 +11,7 @@ import { useEffect } from 'react';
|
||||
import { useTheme } from 'providers/Theme/index';
|
||||
|
||||
const formatResponse = (data, mode) => {
|
||||
if (!data) {
|
||||
if (data === undefined) {
|
||||
return '';
|
||||
}
|
||||
|
||||
|
@ -38,7 +38,7 @@ export const safeParseJSON = (str) => {
|
||||
};
|
||||
|
||||
export const safeStringifyJSON = (obj, indent = false) => {
|
||||
if (!obj) {
|
||||
if (obj === undefined) {
|
||||
return obj;
|
||||
}
|
||||
try {
|
||||
|
Loading…
Reference in New Issue
Block a user