Skip to content

Commit

Permalink
fix(calls): description optional and null types (#62)
Browse files Browse the repository at this point in the history
  • Loading branch information
genaris authored Dec 3, 2024
1 parent 53f8f62 commit b0a53db
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion packages/calls/src/DidCommCallsService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class DidCommCallsService {
callType: DidCommCallType
offerExpirationTime?: Date
offerStartTime?: Date
description: string
description?: string
parameters: Record<string, unknown>
}) {
const { callType, offerExpirationTime, offerStartTime, description, parameters } = options
Expand Down
2 changes: 1 addition & 1 deletion packages/calls/src/DidcommCallsApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export class DidCommCallsApi {
callType: DidCommCallType
offerExpirationTime?: Date
offerStartTime?: Date
description: string
description?: string
parameters: Record<string, unknown>
}) {
const { connectionId, callType, offerExpirationTime, offerStartTime, description, parameters } = options
Expand Down
5 changes: 3 additions & 2 deletions packages/calls/src/messages/CallOfferMessage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,15 @@ export class CallOfferMessage extends AgentMessage {
@IsOptional()
@Expose({ name: 'offer_expiration_time' })
@DateTransformer()
public offerExpirationTime?: Date | null
public offerExpirationTime?: Date

@IsDate()
@IsOptional()
@DateTransformer()
@Expose({ name: 'offer_start_time' })
public offerStartTime?: Date | null
public offerStartTime?: Date

@IsOptional()
public description?: string

public parameters!: Record<string, unknown>
Expand Down

0 comments on commit b0a53db

Please sign in to comment.