Automattic\WooCommerce\Vendor\Sabberworm\CSS\RuleSet

DeclarationBlock::removeSelectorpublicWC 1.0

Remove one of the selectors of the block.

Метод класса: DeclarationBlock{}

Хуков нет.

Возвращает

true|false.

Использование

$DeclarationBlock = new DeclarationBlock();
$DeclarationBlock->removeSelector( $mSelector );
$mSelector(Selector|строка) (обязательный)
.

Код DeclarationBlock::removeSelector() WC 10.4.3

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;
}