Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions src/account/ModularAccountView.sol
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ abstract contract ModularAccountView is IERC6900AccountView {

/// @inheritdoc IERC6900AccountView
function getExecutionData(bytes4 selector) external view override returns (ExecutionDataView memory data) {
ExecutionStorage storage executionStorage = getAccountStorage().executionStorage[selector];
if (
selector == IERC6900Account.execute.selector || selector == IERC6900Account.executeBatch.selector
|| selector == UUPSUpgradeable.upgradeToAndCall.selector
Expand All @@ -26,16 +27,14 @@ abstract contract ModularAccountView is IERC6900AccountView {
data.module = address(this);
data.allowGlobalValidation = true;
} else {
ExecutionStorage storage executionStorage = getAccountStorage().executionStorage[selector];
data.module = executionStorage.module;
data.skipRuntimeValidation = executionStorage.skipRuntimeValidation;
data.allowGlobalValidation = executionStorage.allowGlobalValidation;

uint256 executionHooksLen = executionStorage.executionHooks.length();
data.executionHooks = new HookConfig[](executionHooksLen);
for (uint256 i = 0; i < executionHooksLen; ++i) {
data.executionHooks[i] = toHookConfig(executionStorage.executionHooks.at(i));
}
}
uint256 executionHooksLen = executionStorage.executionHooks.length();
data.executionHooks = new HookConfig[](executionHooksLen);
for (uint256 i = 0; i < executionHooksLen; ++i) {
data.executionHooks[i] = toHookConfig(executionStorage.executionHooks.at(i));
}
}

Expand Down