File tree Expand file tree Collapse file tree 3 files changed +9
-8
lines changed
Expand file tree Collapse file tree 3 files changed +9
-8
lines changed Original file line number Diff line number Diff line change @@ -13,6 +13,6 @@ export default (
1313 parameters : get (
1414 d ,
1515 "body.hydra:search.hydra:mapping"
16- ) as IriTemplateMapping [ ] ,
16+ ) as unknown as IriTemplateMapping [ ] ,
1717 } ) ) ;
1818} ;
Original file line number Diff line number Diff line change @@ -149,11 +149,11 @@ function findRelatedClass(
149149 const onProperty = get (
150150 range ,
151151 '["http://www.w3.org/2002/07/owl#equivalentClass"][0]["http://www.w3.org/2002/07/owl#onProperty"][0]["@id"]'
152- ) as string ;
152+ ) as unknown as string ;
153153 const allValuesFrom = get (
154154 range ,
155155 '["http://www.w3.org/2002/07/owl#equivalentClass"][0]["http://www.w3.org/2002/07/owl#allValuesFrom"][0]["@id"]'
156- ) as string ;
156+ ) as unknown as string ;
157157
158158 if (
159159 allValuesFrom &&
@@ -256,13 +256,13 @@ export default function parseHydraDocumentation(
256256 const supportedProperty = get (
257257 supportedProperties ,
258258 '["http://www.w3.org/ns/hydra/core#property"][0]'
259- ) as ExpandedRdfProperty ;
259+ ) as unknown as ExpandedRdfProperty ;
260260 const id = supportedProperty [ "@id" ] ;
261261 const range = get (
262262 supportedProperty ,
263263 '["http://www.w3.org/2000/01/rdf-schema#range"][0]["@id"]' ,
264264 null
265- ) as string ;
265+ ) as unknown as string ;
266266
267267 const field = new Field (
268268 supportedProperty [ "http://www.w3.org/2000/01/rdf-schema#label" ] [ 0 ] [
Original file line number Diff line number Diff line change @@ -10,8 +10,9 @@ import getType from "./getType.js";
1010import type { OpenAPIV3 } from "openapi-types" ;
1111import type { OperationType } from "../Operation.js" ;
1212
13- const isRef = < T > ( maybeRef : T | OpenAPIV3 . ReferenceObject ) : maybeRef is T =>
14- ! ( "$ref" in maybeRef ) ;
13+ const isRef = < T extends object > (
14+ maybeRef : T | OpenAPIV3 . ReferenceObject
15+ ) : maybeRef is T => ! ( "$ref" in maybeRef ) ;
1516
1617export const removeTrailingSlash = ( url : string ) : string => {
1718 if ( url . endsWith ( "/" ) ) {
@@ -180,7 +181,7 @@ export default async function (
180181 ? ( get (
181182 editOperation ,
182183 "requestBody.content.application/json.schema"
183- ) as OpenAPIV3 . SchemaObject )
184+ ) as unknown as OpenAPIV3 . SchemaObject )
184185 : null ;
185186
186187 if ( ! showSchema && ! editSchema ) return ;
You can’t perform that action at this time.
0 commit comments