Skip to content

Commit

Permalink
Merge pull request #29 from ibdotxyz/typo
Browse files Browse the repository at this point in the history
fix typo
  • Loading branch information
ib-tycho authored Aug 19, 2022
2 parents 27ed4f4 + 7059eef commit a059518
Show file tree
Hide file tree
Showing 20 changed files with 44 additions and 44 deletions.
4 changes: 2 additions & 2 deletions contracts/CCollateralCapErc20.sol
Original file line number Diff line number Diff line change
Expand Up @@ -553,7 +553,7 @@ contract CCollateralCapErc20 is CToken, CCollateralCapErc20Interface {
function decreaseUserCollateralInternal(address account, uint256 amount) internal {
/*
* Return if amount is zero.
* Put behind `redeemAllowed` for accuring potential COMP rewards.
* Put behind `redeemAllowed` for accruing potential COMP rewards.
*/
if (amount == 0) {
return;
Expand Down Expand Up @@ -592,7 +592,7 @@ contract CCollateralCapErc20 is CToken, CCollateralCapErc20Interface {

/*
* Return if mintAmount is zero.
* Put behind `mintAllowed` for accuring potential COMP rewards.
* Put behind `mintAllowed` for accruing potential COMP rewards.
*/
if (mintAmount == 0) {
return (uint256(Error.NO_ERROR), 0);
Expand Down
4 changes: 2 additions & 2 deletions contracts/CCollateralCapErc20CheckRepay.sol
Original file line number Diff line number Diff line change
Expand Up @@ -554,7 +554,7 @@ contract CCollateralCapErc20CheckRepay is CTokenCheckRepay, CCollateralCapErc20I
function decreaseUserCollateralInternal(address account, uint256 amount) internal {
/*
* Return if amount is zero.
* Put behind `redeemAllowed` for accuring potential COMP rewards.
* Put behind `redeemAllowed` for accruing potential COMP rewards.
*/
if (amount == 0) {
return;
Expand Down Expand Up @@ -593,7 +593,7 @@ contract CCollateralCapErc20CheckRepay is CTokenCheckRepay, CCollateralCapErc20I

/*
* Return if mintAmount is zero.
* Put behind `mintAllowed` for accuring potential COMP rewards.
* Put behind `mintAllowed` for accruing potential COMP rewards.
*/
if (mintAmount == 0) {
return (uint256(Error.NO_ERROR), 0);
Expand Down
4 changes: 2 additions & 2 deletions contracts/CCollateralCapErc20NoInterest.sol
Original file line number Diff line number Diff line change
Expand Up @@ -554,7 +554,7 @@ contract CCollateralCapErc20NoInterest is CTokenNoInterest, CCollateralCapErc20I
function decreaseUserCollateralInternal(address account, uint256 amount) internal {
/*
* Return if amount is zero.
* Put behind `redeemAllowed` for accuring potential COMP rewards.
* Put behind `redeemAllowed` for accruing potential COMP rewards.
*/
if (amount == 0) {
return;
Expand Down Expand Up @@ -593,7 +593,7 @@ contract CCollateralCapErc20NoInterest is CTokenNoInterest, CCollateralCapErc20I

/*
* Return if mintAmount is zero.
* Put behind `mintAllowed` for accuring potential COMP rewards.
* Put behind `mintAllowed` for accruing potential COMP rewards.
*/
if (mintAmount == 0) {
return (uint256(Error.NO_ERROR), 0);
Expand Down
6 changes: 3 additions & 3 deletions contracts/CErc20.sol
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ contract CErc20 is CToken, CErc20Interface {

/*
* Return if mintAmount is zero.
* Put behind `mintAllowed` for accuring potential COMP rewards.
* Put behind `mintAllowed` for accruing potential COMP rewards.
*/
if (mintAmount == 0) {
return (uint256(Error.NO_ERROR), 0);
Expand Down Expand Up @@ -402,7 +402,7 @@ contract CErc20 is CToken, CErc20Interface {

/*
* Return if redeemTokensIn and redeemAmountIn are zero.
* Put behind `redeemAllowed` for accuring potential COMP rewards.
* Put behind `redeemAllowed` for accruing potential COMP rewards.
*/
if (redeemTokensIn == 0 && redeemAmountIn == 0) {
return uint256(Error.NO_ERROR);
Expand Down Expand Up @@ -472,7 +472,7 @@ contract CErc20 is CToken, CErc20Interface {

/*
* Return if seizeTokens is zero.
* Put behind `seizeAllowed` for accuring potential COMP rewards.
* Put behind `seizeAllowed` for accruing potential COMP rewards.
*/
if (seizeTokens == 0) {
return uint256(Error.NO_ERROR);
Expand Down
2 changes: 1 addition & 1 deletion contracts/CErc20Delegator.sol
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ contract CErc20Delegator is CTokenInterface, CErc20Interface, CDelegatorInterfac
)
);

// New implementations always get set via the settor (post-initialize)
// New implementations always get set via the setter (post-initialize)
_setImplementation(implementation_, false, becomeImplementationData);

// Set the proper admin now that initialization is done
Expand Down
4 changes: 2 additions & 2 deletions contracts/CToken.sol
Original file line number Diff line number Diff line change
Expand Up @@ -537,7 +537,7 @@ contract CToken is CTokenInterface, Exponential, TokenErrorReporter {
* @notice Borrows are repaid by another user (possibly the borrower).
* @param payer the account paying off the borrow
* @param borrower the account with the debt being payed off
* @param repayAmount the amount of undelrying tokens being returned
* @param repayAmount the amount of underlying tokens being returned
* @param isNative The amount is in native or not
* @return (uint, uint) An error code (0=success, otherwise a failure, see ErrorReporter.sol), and the actual repayment amount.
*/
Expand Down Expand Up @@ -1037,7 +1037,7 @@ contract CToken is CTokenInterface, Exponential, TokenErrorReporter {
) internal returns (uint256);

/**
* @dev Performs a transfer out, ideally returning an explanatory error code upon failure tather than reverting.
* @dev Performs a transfer out, ideally returning an explanatory error code upon failure rather than reverting.
* If caller has not called checked protocol's balance, may revert due to insufficient cash held in the contract.
* If caller has checked protocol's balance, and verified it is >= amount, this should not revert in normal conditions.
*/
Expand Down
4 changes: 2 additions & 2 deletions contracts/CTokenCheckRepay.sol
Original file line number Diff line number Diff line change
Expand Up @@ -537,7 +537,7 @@ contract CTokenCheckRepay is CTokenInterface, Exponential, TokenErrorReporter {
* @notice Borrows are repaid by another user (possibly the borrower).
* @param payer the account paying off the borrow
* @param borrower the account with the debt being payed off
* @param repayAmount the amount of undelrying tokens being returned
* @param repayAmount the amount of underlying tokens being returned
* @param isNative The amount is in native or not
* @param isFromLiquidation The request is from liquidation or not
* @return (uint, uint) An error code (0=success, otherwise a failure, see ErrorReporter.sol), and the actual repayment amount.
Expand Down Expand Up @@ -1056,7 +1056,7 @@ contract CTokenCheckRepay is CTokenInterface, Exponential, TokenErrorReporter {
) internal returns (uint256);

/**
* @dev Performs a transfer out, ideally returning an explanatory error code upon failure tather than reverting.
* @dev Performs a transfer out, ideally returning an explanatory error code upon failure rather than reverting.
* If caller has not called checked protocol's balance, may revert due to insufficient cash held in the contract.
* If caller has checked protocol's balance, and verified it is >= amount, this should not revert in normal conditions.
*/
Expand Down
4 changes: 2 additions & 2 deletions contracts/CTokenInterfaces.sol
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ contract CWrappedNativeInterface is CErc20Interface {
/*** Market Events ***/

/**
* @notice Event emitted when a flashloan occured
* @notice Event emitted when a flashloan occurred
*/
event Flashloan(address indexed receiver, uint256 amount, uint256 totalFee, uint256 reservesFee);

Expand Down Expand Up @@ -409,7 +409,7 @@ contract CCapableErc20Interface is CErc20Interface, CSupplyCapStorage {
/*** Market Events ***/

/**
* @notice Event emitted when a flashloan occured
* @notice Event emitted when a flashloan occurred
*/
event Flashloan(address indexed receiver, uint256 amount, uint256 totalFee, uint256 reservesFee);

Expand Down
4 changes: 2 additions & 2 deletions contracts/CTokenNoInterest.sol
Original file line number Diff line number Diff line change
Expand Up @@ -566,7 +566,7 @@ contract CTokenNoInterest is CTokenInterface, Exponential, TokenErrorReporter {
* @notice Borrows are repaid by another user (possibly the borrower).
* @param payer the account paying off the borrow
* @param borrower the account with the debt being payed off
* @param repayAmount the amount of undelrying tokens being returned
* @param repayAmount the amount of underlying tokens being returned
* @param isNative The amount is in native or not
* @return (uint, uint) An error code (0=success, otherwise a failure, see ErrorReporter.sol), and the actual repayment amount.
*/
Expand Down Expand Up @@ -1066,7 +1066,7 @@ contract CTokenNoInterest is CTokenInterface, Exponential, TokenErrorReporter {
) internal returns (uint256);

/**
* @dev Performs a transfer out, ideally returning an explanatory error code upon failure tather than reverting.
* @dev Performs a transfer out, ideally returning an explanatory error code upon failure rather than reverting.
* If caller has not called checked protocol's balance, may revert due to insufficient cash held in the contract.
* If caller has checked protocol's balance, and verified it is >= amount, this should not revert in normal conditions.
*/
Expand Down
6 changes: 3 additions & 3 deletions contracts/CWrappedNative.sol
Original file line number Diff line number Diff line change
Expand Up @@ -551,7 +551,7 @@ contract CWrappedNative is CToken, CWrappedNativeInterface {

/*
* Return if mintAmount is zero.
* Put behind `mintAllowed` for accuring potential COMP rewards.
* Put behind `mintAllowed` for accruing potential COMP rewards.
*/
if (mintAmount == 0) {
return (uint256(Error.NO_ERROR), 0);
Expand Down Expand Up @@ -656,7 +656,7 @@ contract CWrappedNative is CToken, CWrappedNativeInterface {

/*
* Return if redeemTokensIn and redeemAmountIn are zero.
* Put behind `redeemAllowed` for accuring potential COMP rewards.
* Put behind `redeemAllowed` for accruing potential COMP rewards.
*/
if (redeemTokensIn == 0 && redeemAmountIn == 0) {
return uint256(Error.NO_ERROR);
Expand Down Expand Up @@ -726,7 +726,7 @@ contract CWrappedNative is CToken, CWrappedNativeInterface {

/*
* Return if seizeTokens is zero.
* Put behind `seizeAllowed` for accuring potential COMP rewards.
* Put behind `seizeAllowed` for accruing potential COMP rewards.
*/
if (seizeTokens == 0) {
return uint256(Error.NO_ERROR);
Expand Down
2 changes: 1 addition & 1 deletion contracts/CWrappedNativeDelegator.sol
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ contract CWrappedNativeDelegator is CTokenInterface, CWrappedNativeInterface, CD
)
);

// New implementations always get set via the settor (post-initialize)
// New implementations always get set via the setter (post-initialize)
_setImplementation(implementation_, false, becomeImplementationData);

// Set the proper admin now that initialization is done
Expand Down
4 changes: 2 additions & 2 deletions contracts/Comptroller.sol
Original file line number Diff line number Diff line change
Expand Up @@ -592,7 +592,7 @@ contract Comptroller is ComptrollerV1Storage, ComptrollerInterface, ComptrollerE
) external returns (uint256) {
// Pausing is a very serious situation - we revert to sound the alarms
require(!seizeGuardianPaused, "seize is paused");
require(!isCreditAccount(borrower, cTokenBorrowed), "cannot sieze from credit account");
require(!isCreditAccount(borrower, cTokenBorrowed), "cannot seize from credit account");

// Shh - currently unused
liquidator;
Expand Down Expand Up @@ -1141,7 +1141,7 @@ contract Comptroller is ComptrollerV1Storage, ComptrollerInterface, ComptrollerE
}

/**
* @notice Set the given supply caps for the given cToken markets. Supplying that brings total supplys to or above supply cap will revert.
* @notice Set the given supply caps for the given cToken markets. Supplying that brings total supplies to or above supply cap will revert.
* @dev Admin or pauseGuardian function to set the supply caps. A supply cap of 0 corresponds to unlimited supplying. If the total borrows
* already exceeded the cap, it will prevent anyone to borrow.
* @param cTokens The addresses of the markets (tokens) to change the supply caps for
Expand Down
14 changes: 7 additions & 7 deletions contracts/ComptrollerStorage.sol
Original file line number Diff line number Diff line change
Expand Up @@ -97,27 +97,27 @@ contract ComptrollerV1Storage is UnitrollerAdminStorage {
CToken[] public allMarkets;

/// @notice The portion of compRate that each market currently receives
/// @dev This storage is depreacted.
/// @dev This storage is deprecated.
mapping(address => uint256) public compSpeeds;

/// @notice The COMP market supply state for each market
/// @dev This storage is depreacted.
/// @dev This storage is deprecated.
mapping(address => CompMarketState) public compSupplyState;

/// @notice The COMP market borrow state for each market
/// @dev This storage is depreacted.
/// @dev This storage is deprecated.
mapping(address => CompMarketState) public compBorrowState;

/// @notice The COMP borrow index for each market for each supplier as of the last time they accrued COMP
/// @dev This storage is depreacted.
/// @dev This storage is deprecated.
mapping(address => mapping(address => uint256)) public compSupplierIndex;

/// @notice The COMP borrow index for each market for each borrower as of the last time they accrued COMP
/// @dev This storage is depreacted.
/// @dev This storage is deprecated.
mapping(address => mapping(address => uint256)) public compBorrowerIndex;

/// @notice The COMP accrued but not yet transferred to each user
/// @dev This storage is depreacted.
/// @dev This storage is deprecated.
mapping(address => uint256) public compAccrued;

/// @notice The borrowCapGuardian can set borrowCaps to any number for any market. Lowering the borrow cap could disable borrowing on the given market.
Expand All @@ -133,7 +133,7 @@ contract ComptrollerV1Storage is UnitrollerAdminStorage {
mapping(address => uint256) public supplyCaps;

/// @notice creditLimits allowed specific protocols to borrow and repay without collateral.
/// @dev This storage is depreacted.
/// @dev This storage is deprecated.
mapping(address => uint256) internal _oldCreditLimits;

/// @notice flashloanGuardianPaused can pause flash loan as a safety mechanism.
Expand Down
4 changes: 2 additions & 2 deletions contracts/InterestRateModel.sol
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ contract InterestRateModel {
* @notice Calculates the current borrow interest rate per block
* @param cash The total amount of cash the market has
* @param borrows The total amount of borrows the market has outstanding
* @param reserves The total amnount of reserves the market has
* @param reserves The total amount of reserves the market has
* @return The borrow rate per block (as a percentage, and scaled by 1e18)
*/
function getBorrowRate(
Expand All @@ -25,7 +25,7 @@ contract InterestRateModel {
* @notice Calculates the current supply interest rate per block
* @param cash The total amount of cash the market has
* @param borrows The total amount of borrows the market has outstanding
* @param reserves The total amnount of reserves the market has
* @param reserves The total amount of reserves the market has
* @param reserveFactorMantissa The current reserve factor the market has
* @return The supply rate per block (as a percentage, and scaled by 1e18)
*/
Expand Down
6 changes: 3 additions & 3 deletions contracts/Legacy/CCapableErc20.sol
Original file line number Diff line number Diff line change
Expand Up @@ -373,7 +373,7 @@ contract CCapableErc20 is CToken, CCapableErc20Interface {

/*
* Return if mintAmount is zero.
* Put behind `mintAllowed` for accuring potential COMP rewards.
* Put behind `mintAllowed` for accruing potential COMP rewards.
*/
if (mintAmount == 0) {
return (uint256(Error.NO_ERROR), 0);
Expand Down Expand Up @@ -483,7 +483,7 @@ contract CCapableErc20 is CToken, CCapableErc20Interface {

/*
* Return if redeemTokensIn and redeemAmountIn are zero.
* Put behind `redeemAllowed` for accuring potential COMP rewards.
* Put behind `redeemAllowed` for accruing potential COMP rewards.
*/
if (redeemTokensIn == 0 && redeemAmountIn == 0) {
return uint256(Error.NO_ERROR);
Expand Down Expand Up @@ -557,7 +557,7 @@ contract CCapableErc20 is CToken, CCapableErc20Interface {

/*
* Return if seizeTokens is zero.
* Put behind `seizeAllowed` for accuring potential COMP rewards.
* Put behind `seizeAllowed` for accruing potential COMP rewards.
*/
if (seizeTokens == 0) {
return uint256(Error.NO_ERROR);
Expand Down
2 changes: 1 addition & 1 deletion contracts/Legacy/CCollateralCapErc20Delegator.sol
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ contract CCollateralCapErc20Delegator is CTokenInterface, CCollateralCapErc20Int
)
);

// New implementations always get set via the settor (post-initialize)
// New implementations always get set via the setter (post-initialize)
_setImplementation(implementation_, false, becomeImplementationData);

// Set the proper admin now that initialization is done
Expand Down
4 changes: 2 additions & 2 deletions contracts/Legacy/CTokenDeprecated.sol
Original file line number Diff line number Diff line change
Expand Up @@ -734,7 +734,7 @@ contract CTokenDeprecated is CTokenInterface, Exponential, TokenErrorReporter {
* @notice Borrows are repaid by another user (possibly the borrower).
* @param payer the account paying off the borrow
* @param borrower the account with the debt being payed off
* @param repayAmount the amount of undelrying tokens being returned
* @param repayAmount the amount of underlying tokens being returned
* @return (uint, uint) An error code (0=success, otherwise a failure, see ErrorReporter.sol), and the actual repayment amount.
*/
function repayBorrowFresh(
Expand Down Expand Up @@ -1313,7 +1313,7 @@ contract CTokenDeprecated is CTokenInterface, Exponential, TokenErrorReporter {
function doTransferIn(address from, uint256 amount) internal returns (uint256);

/**
* @dev Performs a transfer out, ideally returning an explanatory error code upon failure tather than reverting.
* @dev Performs a transfer out, ideally returning an explanatory error code upon failure rather than reverting.
* If caller has not called checked protocol's balance, may revert due to insufficient cash held in the contract.
* If caller has checked protocol's balance, and verified it is >= amount, this should not revert in normal conditions.
*/
Expand Down
2 changes: 1 addition & 1 deletion contracts/Legacy/ComptrollerG1.sol
Original file line number Diff line number Diff line change
Expand Up @@ -1104,7 +1104,7 @@ contract ComptrollerG1 is ComptrollerV1Storage, ComptrollerInterface, Comptrolle
}

/**
* @notice Set the given supply caps for the given cToken markets. Supplying that brings total supplys to or above supply cap will revert.
* @notice Set the given supply caps for the given cToken markets. Supplying that brings total supplies to or above supply cap will revert.
* @dev Admin or supplyCapGuardian function to set the supply caps. A supply cap of 0 corresponds to unlimited supplying.
* @param cTokens The addresses of the markets (tokens) to change the supply caps for
* @param newSupplyCaps The new supply cap values in underlying to be set. A value of 0 corresponds to unlimited supplying.
Expand Down
4 changes: 2 additions & 2 deletions contracts/PriceOracle/PriceOracleProxy.sol
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ contract PriceOracleProxy is PriceOracle, Exponential, Denominations {
return getTokenPrice(underlying);
}

/*** Internal fucntions ***/
/*** Internal functions ***/

/**
* @notice Get the price of a specific token. Return 1e18 is it's WETH.
Expand Down Expand Up @@ -186,7 +186,7 @@ contract PriceOracleProxy is PriceOracle, Exponential, Denominations {
/**
* @notice Get price from ChainLink
* @param base The base token that ChainLink aggregator gets the price of
* @param quote The quote token, currenlty support ETH and USD
* @param quote The quote token, currently support ETH and USD
* @return The price, scaled by 1e18
*/
function getPriceFromChainlink(address base, address quote) internal view returns (uint256) {
Expand Down
4 changes: 2 additions & 2 deletions contracts/PriceOracle/PriceOracleProxyIB.sol
Original file line number Diff line number Diff line change
Expand Up @@ -109,12 +109,12 @@ contract PriceOracleProxyIB is PriceOracle, Exponential, Denominations {
revert("no price");
}

/*** Internal fucntions ***/
/*** Internal functions ***/

/**
* @notice Get price from ChainLink
* @param base The base token that ChainLink aggregator gets the price of
* @param quote The quote token, currenlty support ETH and USD
* @param quote The quote token, currently support ETH and USD
* @return The price, scaled by 1e18
*/
function getPriceFromChainlink(address base, address quote) internal view returns (uint256) {
Expand Down

0 comments on commit a059518

Please sign in to comment.