mirror of
https://github.com/GitbookIO/gitbook.git
synced 2026-09-12 05:48:57 +00:00
Fix typing of shouldIgnoreEntity (#2906)
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@gitbook/openapi-parser': patch
|
||||
---
|
||||
|
||||
Fix typing of `shouldIgnoreEntity`
|
||||
@@ -4,10 +4,7 @@ import type { OpenAPIV3 } from '@scalar/openapi-types';
|
||||
* Check if an entity should be ignored
|
||||
*/
|
||||
export function shouldIgnoreEntity(
|
||||
data:
|
||||
| undefined
|
||||
| Pick<OpenAPIV3.TagObject, 'x-internal' | 'x-gitbook-ignore'>
|
||||
| Pick<OpenAPIV3.OperationObject, 'x-internal' | 'x-gitbook-ignore'>
|
||||
data: undefined | OpenAPIV3.TagObject | OpenAPIV3.OperationObject
|
||||
) {
|
||||
return data?.['x-internal'] === true || data?.['x-gitbook-ignore'] === true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user