You are here

public function AcquiaPurgeProcessorAjax::onInit in Acquia Purge 7

Implements event onInit.

See also

acquia_purge_init()

File

lib/processor/AcquiaPurgeProcessorAjax.php, line 82
Contains AcquiaPurgeProcessorAjax.

Class

AcquiaPurgeProcessorAjax
Process the queue using a AJAX client-side UI.

Code

public function onInit() {

  // Do not trigger the on-screen purger if this path is blacklisted.
  if (!$this
    ->isPathBlacklisted()) {

    // Check if this user needs the client-side processor loaded.
    if (self::isUserOwningTheQueue($this->service)) {

      // Load the static assets that will kick in the processor.
      $this
        ->initializeClientSideProcessor();
    }
  }
}