Skip to content

Commit b78bb70

Browse files
committed
feat: Updated for semanticHashProperty
1 parent d427318 commit b78bb70

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/apitypes/rest/rest.operations.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ export const buildRestOperations: OperationsBuilder<OpenAPIV3.Document> = async
3636
{
3737
...NORMALIZE_OPTIONS,
3838
originsFlag: ORIGINS_SYMBOL,
39-
hashFlag: HASH_FLAG,
39+
semanticHashProperty: HASH_FLAG,
4040
source: document.data,
4141
onRefResolveError: (message: string, _path: PropertyKey[], _ref: string, errorType: RefErrorType) =>
4242
bundlingErrorHandler([{ message, errorType }]),

src/components/deprecated.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ import { executeInBatches, isDeprecatedOperationItem, isString, keyBy } from '..
2020
import { JsonPath } from '@netcracker/qubership-apihub-json-crawl'
2121
import { areDeclarationPathsEqual } from '../utils/path'
2222
import {
23-
DeferredHash,
2423
grepValue,
24+
Hash,
2525
Jso,
2626
matchPaths,
2727
OPEN_API_PROPERTY_COMPONENTS,
@@ -132,8 +132,8 @@ export const matchSharedComponent = (jsonPath: JsonPath): MatchResult | undefine
132132

133133
export function calculateTolerantHash(value: Jso, notifications: NotificationMessage[]): string | undefined {
134134
try {
135-
const tolerantHash = Object.keys(value).length > 0
136-
? HASH_FLAG in value ? value[HASH_FLAG] as DeferredHash | undefined : undefined
135+
const tolerantHash: Hash | undefined = Object.keys(value).length > 0
136+
? HASH_FLAG in value ? value[HASH_FLAG] as Hash | undefined : undefined
137137
: undefined
138138

139139
if (!tolerantHash) {
@@ -143,7 +143,7 @@ export function calculateTolerantHash(value: Jso, notifications: NotificationMes
143143
})
144144
return undefined
145145
}
146-
return tolerantHash()
146+
return tolerantHash
147147
} catch (error) {
148148
notifications.push({
149149
severity: MESSAGE_SEVERITY.Error,

0 commit comments

Comments
 (0)