fix: resolve webhooks and content items problem

This commit is contained in:
Alex Varchuk 2021-05-27 15:43:08 +03:00
parent 456666eaa2
commit 0c91eef92f
2 changed files with 3 additions and 2 deletions

View File

@ -15,7 +15,7 @@ export class ContentItems extends React.Component<{
render() {
const items = this.props.items;
if (items.length === 0) {
return <MiddlePanel compact={false}>Cannot find path or webhooks items</MiddlePanel>;
return null;
}
return items.map(item => {
return <ContentItem key={item.id} item={item} />;

View File

@ -238,7 +238,8 @@ export class MenuBuilder {
const operationInfo = path[operationName];
if (path.$ref) {
const resolvedPaths = parser.deref<OpenAPIPaths>(path as OpenAPIPaths);
getTags(parser, { [operationName]: resolvedPaths }, isWebhook);
getTags(parser, { [pathName]: resolvedPaths }, isWebhook);
continue;
}
let operationTags = operationInfo?.tags;