bug(#699): fixed crashing app on clicking on request result in runner

This commit is contained in:
Martin Sefcik 2023-10-20 14:34:04 +02:00
parent f8f38802a9
commit 55c52971d6
3 changed files with 4 additions and 2 deletions

View File

@ -35,7 +35,7 @@ const formatResponse = (data, mode) => {
return safeStringifyJSON(data); return safeStringifyJSON(data);
}; };
const QueryResult = ({ item, collection, data, width, disableRunEventListener, headers, error }) => { const QueryResult = ({ item, collection, data, dataBuffer, width, disableRunEventListener, headers, error }) => {
const contentType = getContentType(headers); const contentType = getContentType(headers);
const mode = getCodeMirrorModeBasedOnContentType(contentType); const mode = getCodeMirrorModeBasedOnContentType(contentType);
const formattedData = formatResponse(data, mode); const formattedData = formatResponse(data, mode);
@ -90,7 +90,7 @@ const QueryResult = ({ item, collection, data, width, disableRunEventListener, h
<QueryResultPreview <QueryResultPreview
previewTab={previewTab} previewTab={previewTab}
data={data} data={data}
dataBuffer={item.response.dataBuffer} dataBuffer={dataBuffer}
formattedData={formattedData} formattedData={formattedData}
item={item} item={item}
contentType={contentType} contentType={contentType}

View File

@ -41,6 +41,7 @@ const ResponsePane = ({ rightPaneWidth, item, collection }) => {
collection={collection} collection={collection}
width={rightPaneWidth} width={rightPaneWidth}
data={response.data} data={response.data}
dataBuffer={response.dataBuffer}
headers={response.headers} headers={response.headers}
error={response.error} error={response.error}
key={item.filename} key={item.filename}

View File

@ -34,6 +34,7 @@ const ResponsePane = ({ rightPaneWidth, item, collection }) => {
width={rightPaneWidth} width={rightPaneWidth}
disableRunEventListener={true} disableRunEventListener={true}
data={responseReceived.data} data={responseReceived.data}
dataBuffer={responseReceived.dataBuffer}
headers={responseReceived.headers} headers={responseReceived.headers}
key={item.filename} key={item.filename}
/> />