Skip to content

Commit 1e5189e

Browse files
committed
Updating readme
1 parent 9ec1d13 commit 1e5189e

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -339,12 +339,12 @@ Hooks are a way to invoke functions and then invoke certain behaviors inside the
339339

340340
**Signature**:
341341
`cacheContractHook = async (action: () => Promise<any> | any,
342-
contractId?: string,
342+
contractId?: string | string[],
343343
refreshCommunityContract?: boolean)`
344344

345345
**Parameters**:
346346
*action*: Action to be called inside before executing the hook
347-
*contractId*: Contract to be cached right after `action` has finished its execution
347+
*contractId*: Contract to be cached right after `action` has finished its execution. If an array, it'll cache all the ids provided in the array.
348348
*refreshCommunityContract*: Whether the community contract should be updated after `action` has finished its execution
349349

350350
**Usage**:
@@ -353,6 +353,7 @@ refreshCommunityContract?: boolean)`
353353
import { cacheContractHook } from 'verto-cace-interface';
354354

355355
const currentContract: string = 'ABCD1234'
356+
// const currentContracts: string[] = ['ABCD1234', '12903LLLEP'];
356357

357358
const executeOrder = await cacheContractHook(async () => {
358359
// Execute an order inside the exchange

0 commit comments

Comments
 (0)