Skip to content
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -805,13 +805,14 @@ contract OPContractsManagerV2 is ISemver, OPContractsManagerUtilsCaller {
}

// If the custom gas token feature was requested, enable it in the SystemConfig.
if (_cfg.useCustomGasToken && !_cts.systemConfig.isFeatureEnabled(Features.CUSTOM_GAS_TOKEN)) {
if (_cfg.useCustomGasToken) {
// NOTE: Enabling the custom gas token feature is only allowed during initial deployment to prevent
// chains from enabling it during upgrades. Passing in true for this flag during an upgrade is considered an
// error and will revert.
if (!_isInitialDeployment) {
revert OPContractsManagerV2_CannotUpgradeToCustomGasToken();
}

_cts.systemConfig.setFeature(Features.CUSTOM_GAS_TOKEN, true);
}

Expand Down