Skip to content

Commit

Permalink
feat: allow to use VRF in dryWrite
Browse files Browse the repository at this point in the history
  • Loading branch information
rpiszczatowski committed Mar 15, 2023
1 parent c2c4ac0 commit b1af2ba
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/contract/Contract.ts
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,8 @@ export interface Contract<State = unknown> {
input: Input,
caller?: string,
tags?: Tags,
transfer?: ArTransfer
transfer?: ArTransfer,
vrf?: boolean
): Promise<InteractionResult<State, unknown>>;

applyInput<Input>(input: Input, transaction: GQLNodeInterface): Promise<InteractionResult<State, unknown>>;
Expand Down
5 changes: 3 additions & 2 deletions src/contract/HandlerBasedContract.ts
Original file line number Diff line number Diff line change
Expand Up @@ -228,10 +228,11 @@ export class HandlerBasedContract<State> implements Contract<State> {
input: Input,
caller?: string,
tags?: Tags,
transfer?: ArTransfer
transfer?: ArTransfer,
vrf?: boolean
): Promise<InteractionResult<State, unknown>> {
this.logger.info('Dry-write for', this._contractTxId);
return await this.callContract<Input>(input, 'write', caller, undefined, tags, transfer);
return await this.callContract<Input>(input, 'write', caller, undefined, tags, transfer, undefined, vrf);
}

async applyInput<Input>(input: Input, transaction: GQLNodeInterface): Promise<InteractionResult<State, unknown>> {
Expand Down

0 comments on commit b1af2ba

Please sign in to comment.