Skip to content

Constructors should not make unnecessary external calls #434

@pakim249CAL

Description

@pakim249CAL

constructor(
ISlashingRegistryCoordinator _registryCoordinator
) {
registryCoordinator = _registryCoordinator;
stakeRegistry = _registryCoordinator.stakeRegistry();
blsApkRegistry = _registryCoordinator.blsApkRegistry();
delegation = stakeRegistry.delegation();
}

This prevents an implementation from being deployed before dependent proxies are initialized. IMO there is no upside to doing this because the caller can do the external view calls themselves.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions