You are here

public function ContentSyncSettings::getSiteId in CMS Content Sync 2.1.x

Same name and namespace in other branches
  1. 8 src/Controller/ContentSyncSettings.php \Drupal\cms_content_sync\Controller\ContentSyncSettings::getSiteId()
  2. 2.0.x src/Controller/ContentSyncSettings.php \Drupal\cms_content_sync\Controller\ContentSyncSettings::getSiteId()

Return value

null|string

Throws

\Exception

1 call to ContentSyncSettings::getSiteId()
ContentSyncSettings::getSiteName in src/Controller/ContentSyncSettings.php

File

src/Controller/ContentSyncSettings.php, line 403

Class

ContentSyncSettings
Class ContentSyncSettings.

Namespace

Drupal\cms_content_sync\Controller

Code

public function getSiteId() {
  if (null !== $this->siteId) {
    return $this->siteId;
  }

  // Allow overwritting of the site_id from the global $settings.
  return $this->siteId = Settings::get('cms_content_sync_site_id', \Drupal::state()
    ->get('cms_content_sync.site_id'));
}