diff --git a/package.json b/package.json index e76b4a5..d95faaa 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@orionprotocol/sdk", - "version": "0.19.66", + "version": "0.19.67", "description": "Orion Protocol SDK", "main": "./lib/index.cjs", "module": "./lib/index.js", diff --git a/src/Orion/bridge/getHistory.ts b/src/Orion/bridge/getHistory.ts index 402a163..0cce384 100644 --- a/src/Orion/bridge/getHistory.ts +++ b/src/Orion/bridge/getHistory.ts @@ -140,7 +140,7 @@ const getHistory = async (units: Unit[], address: string, limit = 1000) => { amountToReceive: SourceItem['amountToReceive'] amountToSpend: SourceItem['amountToSpend'] status: { - source: SourceItem['state'] + source?: SourceItem['state'] | undefined target?: TargetItem['state'] | undefined aggregator?: AggItem['status'] | undefined } diff --git a/src/services/BlockchainService/schemas/atomicHistorySchema.ts b/src/services/BlockchainService/schemas/atomicHistorySchema.ts index afe4d40..504145b 100644 --- a/src/services/BlockchainService/schemas/atomicHistorySchema.ts +++ b/src/services/BlockchainService/schemas/atomicHistorySchema.ts @@ -34,7 +34,7 @@ const sourceAtomicHistorySchemaItem = baseAtomicHistoryItem.extend({ expiration: z.object({ lock: z.number().optional(), }).optional(), - state: z.enum(['BEFORE-LOCK', 'LOCKED', 'REFUNDED', 'CLAIMED']), + state: z.enum(['BEFORE-LOCK', 'LOCKED', 'REFUNDED', 'CLAIMED']).optional(), targetChainId: z.number(), transactions: z.object({ lock: z.string().optional(), @@ -51,7 +51,7 @@ const targetAtomicHistorySchemaItem = baseAtomicHistoryItem.extend({ expiration: z.object({ redeem: z.number().optional(), }).optional(), - state: z.enum(['BEFORE-REDEEM', 'REDEEMED']), + state: z.enum(['BEFORE-REDEEM', 'REDEEMED']).optional(), transactions: z.object({ redeem: z.string().optional(), }).optional(),