You are here

public function FlaggingCollectionStorage::clearRevisionsLanguage in Flag Lists 4.0.x

Same name and namespace in other branches
  1. 8 src/FlaggingCollectionStorage.php \Drupal\flag_lists\FlaggingCollectionStorage::clearRevisionsLanguage()

Unsets the language for all Flagging collection with the given language.

Parameters

\Drupal\Core\Language\LanguageInterface $language: The language object.

Overrides FlaggingCollectionStorageInterface::clearRevisionsLanguage

File

src/FlaggingCollectionStorage.php, line 51

Class

FlaggingCollectionStorage
Defines the storage handler class for Flagging collection entities.

Namespace

Drupal\flag_lists

Code

public function clearRevisionsLanguage(LanguageInterface $language) {
  return $this->database
    ->update('flagging_collection_revision')
    ->fields([
    'langcode' => LanguageInterface::LANGCODE_NOT_SPECIFIED,
  ])
    ->condition('langcode', $language
    ->getId())
    ->execute();
}