setTokenFactors
params of setTokenParams -> storage with [ tokens[tokenId] ] upd
Updates token-related factors of the protocol by tokenId
of yToken.
The yToken
contract expects that underlying token info of tokenId
is updated by calling PriceFeed.getPrice and updateInterest in the same block before this call.
Types
Parameter | Type | Description |
---|---|---|
tokenId | nat | token identifier |
collateralFactorF | nat | collateral factor as float number multiplied by |
reserveFactorF | nat | reserve factor as float number multiplied by |
interestRateModel | address | priceFeed proxy contract instance |
maxBorrowRate | nat | |
threshold | nat | |
liquidReserveRateF | nat |
Usage
Errors
yToken/not-admin
-sender
is not contract admin.yToken/need-update
- token price and interest not updated (see warning above)
Last updated