You are here

public function JsonLogData::setTags in JSONlog 8

Same name and namespace in other branches
  1. 8.2 src/Logger/JsonLogData.php \Drupal\jsonlog\Logger\JsonLogData::setTags()
  2. 3.x src/Logger/JsonLogData.php \Drupal\jsonlog\Logger\JsonLogData::setTags()

Parameters

string $tags_server:

string $tags_site:

File

src/Logger/JsonLogData.php, line 204

Class

JsonLogData

Namespace

Drupal\jsonlog\Logger

Code

public function setTags($tags_server, $tags_site) {
  if ($tags_server) {
    $tags = $tags_server;
    if ($tags_site) {
      $tags .= ',' . $tags_site;
    }
  }
  else {
    $tags = $tags_site;
  }
  if ($tags) {
    $this->tags = explode(',', $tags);
  }
}