Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. LanguageConfigOverride.php

function LanguageConfigOverride::delete

Overrides StorableConfigBase::delete

File

core/modules/language/src/Config/LanguageConfigOverride.php, line 80

Class

LanguageConfigOverride
Defines language configuration overrides.

Namespace

Drupal\language\Config

Code

public function delete() {
    $this->data = [];
    $this->storage
        ->delete($this->name);
    Cache::invalidateTags($this->getCacheTags());
    $this->isNew = TRUE;
    // Dispatch configuration override event as detailed in
    // \Drupal\Core\Config\ConfigFactoryOverrideInterface::createConfigObject().
    $this->eventDispatcher
        ->dispatch(new ConfigCrudEvent($this), ConfigCollectionEvents::DELETE_IN_COLLECTION);
    // Dispatch an event specifically for language configuration override
    // changes.
    $this->eventDispatcher
        ->dispatch(new LanguageConfigOverrideCrudEvent($this), LanguageConfigOverrideEvents::DELETE_OVERRIDE);
    $this->originalData = $this->data;
    return $this;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal