mirror of
https://github.com/Instadapp/aave-protocol-v2.git
synced 2024-07-29 21:47:30 +00:00
Updated events on debt tokens
This commit is contained in:
parent
191f65c7f0
commit
3c3a01b80f
|
@ -132,6 +132,9 @@ contract StableDebtToken is IStableDebtToken, DebtTokenBase {
|
|||
|
||||
_mint(user, amount.add(balanceIncrease));
|
||||
|
||||
// transfer event to track balances
|
||||
emit Transfer(address(0), user, amount);
|
||||
|
||||
emit MintDebt(
|
||||
user,
|
||||
amount,
|
||||
|
@ -180,6 +183,9 @@ contract StableDebtToken is IStableDebtToken, DebtTokenBase {
|
|||
_burn(user, amount.sub(balanceIncrease));
|
||||
}
|
||||
|
||||
// transfer event to track balances
|
||||
emit Transfer(user, address(0), amount);
|
||||
|
||||
emit BurnDebt(user, amount, previousBalance, currentBalance, balanceIncrease);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -79,6 +79,7 @@ contract VariableDebtToken is DebtTokenBase, IVariableDebtToken {
|
|||
require(newUserIndex < (1 << 128), 'Debt token: Index overflow');
|
||||
_usersData[user] = newUserIndex;
|
||||
|
||||
emit Transfer(address(0), user, amount);
|
||||
emit MintDebt(user, amount, previousBalance, currentBalance, balanceIncrease, newUserIndex);
|
||||
}
|
||||
|
||||
|
@ -108,6 +109,8 @@ contract VariableDebtToken is DebtTokenBase, IVariableDebtToken {
|
|||
}
|
||||
_usersData[user] = newUserIndex;
|
||||
|
||||
// transfer event to track the balances
|
||||
emit Transfer(user, address(0), amount);
|
||||
emit BurnDebt(user, amount, previousBalance, currentBalance, balanceIncrease, newUserIndex);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user