Skip to content

gas analysis: Single reserve event emission for dynamic config update#1168

Draft
CheyenneAtapour wants to merge 11 commits intodevfrom
gas/single-events
Draft

gas analysis: Single reserve event emission for dynamic config update#1168
CheyenneAtapour wants to merge 11 commits intodevfrom
gas/single-events

Conversation

@CheyenneAtapour
Copy link
Contributor

No description provided.


/// @notice Emitted when a user's dynamic config is refreshed for a single reserve to its latest config key.
/// @param user The address of the user.
/// @param reserveId The identifier of the reserve.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think we should rename this, no need for single. like RefreshUserDynamicConfig

accountData.activeCollateralCount = accountData.activeCollateralCount.uncheckedAdd(1);
}
}
if (refreshConfig) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wonder if it is worth moving up to L740 and combining the logic with the collFactor
anyway stermi had mentioned having the ternary op there was hard to read

// Liquidate alice
vm.prank(bob);
spoke.liquidationCall(collateralReserveId, debtReserveId, alice, 1e18, false);
vm.snapshotGasLastCall(NAMESPACE, 'L. liquidateUser: 2 collaterals');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

think these all should be liquidationCall rather than liquidateUser

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Comments