diff --git a/packages/api-explorer-ui/__tests__/CodeSampleResponse.test.jsx b/packages/api-explorer-ui/__tests__/CodeSampleResponse.test.jsx index d732f85ab..6d8e2c211 100644 --- a/packages/api-explorer-ui/__tests__/CodeSampleResponse.test.jsx +++ b/packages/api-explorer-ui/__tests__/CodeSampleResponse.test.jsx @@ -66,7 +66,6 @@ describe('hideResults', () => { const codeSampleResponseTabs = shallow(); expect(codeSampleResponseTabs.state('result')).toEqual({ - isBinary: false, method: 'POST', requestHeaders: 'Authorization : Bearer api-key', responseHeaders: 'content-disposition,application/json', @@ -131,7 +130,6 @@ describe('Results body', () => { test('should not display responseBody if isBinary is true', () => { const props2 = { result: { - init: true, isBinary: true, method: 'POST', requestHeaders: 'Authorization : Bearer api-key', @@ -151,8 +149,6 @@ describe('Results body', () => { test('should display message if OAuth is incorrect or expired ', () => { const props3 = { result: { - init: true, - isBinary: true, method: 'POST', requestHeaders: 'Authorization : Bearer api-key', responseHeaders: 'content-disposition,application/json', diff --git a/packages/api-explorer-ui/src/CodeSampleResponse.jsx b/packages/api-explorer-ui/src/CodeSampleResponse.jsx index d9488ad1c..c944cc2c4 100644 --- a/packages/api-explorer-ui/src/CodeSampleResponse.jsx +++ b/packages/api-explorer-ui/src/CodeSampleResponse.jsx @@ -51,9 +51,9 @@ class CodeSampleResponse extends React.Component { on: result !== null, })} > -
+
- {result === null ? null : ( + {result !== null && (