Skip to content

Commit

Permalink
chore: tsdoc - getActiveHook
Browse files Browse the repository at this point in the history
  • Loading branch information
joepegler committed Sep 19, 2024
1 parent ba9897c commit 140f9dc
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/sdk/clients/decorators/erc7579/accountId.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { AccountNotFoundError } from "../../../account/utils/AccountNotFound"
*
* @example
* import { accountId } from '@biconomy/sdk'
*
*
* const id = await accountId(nexusClient)
* console.log(id) // 'example_account_id'
*/
Expand Down
14 changes: 14 additions & 0 deletions src/sdk/clients/decorators/erc7579/getActiveHook.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,20 @@ export type GetActiveHookParameters<
TSmartAccount extends SmartAccount | undefined
> = GetSmartAccountParameter<TSmartAccount>

/**
* Retrieves the active hook for a given smart account.
*
* @param client - The client instance.
* @param parameters - Parameters for getting the smart account.
* @returns The address of the active hook as a hexadecimal string.
* @throws {AccountNotFoundError} If the account is not found.
*
* @example
* import { getActiveHook } from '@biconomy/sdk'
*
* const activeHook = await getActiveHook(nexusClient)
* console.log(activeHook) // '0x...'
*/
export async function getActiveHook<
TSmartAccount extends SmartAccount | undefined
>(
Expand Down

0 comments on commit 140f9dc

Please sign in to comment.