getAllowance()

getAllowance is a method that helps get the allowance amount of a given erc20 contract for airdrop contract to spend. It is commonly used to check allowance of payment contract before increaseAllowance

Parameter

ArgumentTypeDescription
descriptionstringthe address of the erc20 token
ownerstringthe address of the owner

Response

PropertyTypeDescription
PromiseBigNumberthe amount of allowance

Example

const allowance = await presaleSdk.getAllowance(paymentToken, await signer.getAddress())