Log in
Model

ScopeValidator

Magento\Store\Model\ScopeValidator

What it does

This class validates whether a given scope (default, website, store) and scope ID combination is valid in Magento 2.

Developers use this when they need to verify that a configuration scope exists before applying settings or performing operations at that scope level.

It's particularly useful when working with multi-store setups or programmatically managing configuration values.

Public Methods

  • isValidScope()