function WorkspacesTestHooks::entityTranslationCreate

Implements hook_ENTITY_TYPE_translation_create() for 'entity_test_mulrevpub'.

Attributes

#[Hook('entity_test_mulrevpub_translation_create')]

File

core/modules/workspaces/tests/modules/workspaces_test/src/Hook/WorkspacesTestHooks.php, line 63

Class

WorkspacesTestHooks
Hook implementations for workspaces_test.

Namespace

Drupal\workspaces_test\Hook

Code

public function entityTranslationCreate() : void {
  $this->keyValueFactory
    ->get('ws_test')
    ->set('workspace_was_active', $this->workspaceManager
    ->hasActiveWorkspace());
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.