You are here

public static function BackendBase::getTemporaryRuntimeError in Acquia Purge 8

Check if a temporary runtime error has been set.

Return value

string Empty string when no runtime error is present.

Overrides BackendInterface::getTemporaryRuntimeError

File

src/AcquiaPlatformCdn/BackendBase.php, line 55

Class

BackendBase
Provides a backend for the Platform CDN purger.

Namespace

Drupal\acquia_purge\AcquiaPlatformCdn

Code

public static function getTemporaryRuntimeError() {
  if ($error = \Drupal::cache()
    ->get('acquia_purge_cdn_runtime_error')) {
    return $error->data;
  }
  return '';
}