Automattic\WooCommerce\Vendor\Sabberworm\CSS\RuleSet

DeclarationBlock::removeSelectorpublicWC 1.0

Remove one of the selectors of the block.

Method of the class: DeclarationBlock{}

No Hooks.

Returns

true|false.

Usage

$DeclarationBlock = new DeclarationBlock();
$DeclarationBlock->removeSelector( $mSelector );
$mSelector(Selector|string) (required)
.

DeclarationBlock::removeSelector() code WC 10.9.4

public function removeSelector($mSelector)
{
    if ($mSelector instanceof Selector) {
        $mSelector = $mSelector->getSelector();
    }
    foreach ($this->aSelectors as $iKey => $oSelector) {
        if ($oSelector->getSelector() === $mSelector) {
            unset($this->aSelectors[$iKey]);
            return true;
        }
    }
    return false;
}