The client instance.
Parameters including the smart account and the module to check.
The address of the previous module, or the sentinel address if it's the first module.
If the account is not found.
If the module type is unknown or the module is not found.
import { getPreviousModule } from '@biconomy/abstractjs'
const previousModuleAddress = await getPreviousModule(nexusClient, {
module: {
type: 'validator',
moduleAddress: '0x...',
}
})
console.log(previousModuleAddress) // '0x...'
Gets the address of the previous module of the same type as the given module.