You are here

public function SecurityReview::setLogging in Security Review 8

Sets the 'logging' flag.

Parameters

bool $logging: The new value of the 'logging' setting.

bool $temporary: Whether to set only temporarily.

File

src/SecurityReview.php, line 149

Class

SecurityReview
A class containing static methods regarding the module's configuration.

Namespace

Drupal\security_review

Code

public function setLogging($logging, $temporary = FALSE) {
  if (!$temporary) {
    $this->config
      ->set('log', $logging);
    $this->config
      ->save();
  }
  else {
    static::$temporaryLogging = $logging == TRUE;
  }
}