You are here

public function QueueBackend::validateArgument in Advanced Queue 8

Performs validation for a given argument.

Overrides ArgumentValidatorPluginBase::validateArgument

File

src/Plugin/views/argument_validator/QueueBackend.php, line 21

Class

QueueBackend
Defines an argument validator plugin for queue backends.

Namespace

Drupal\advancedqueue\Plugin\views\argument_validator

Code

public function validateArgument($arg) {
  $queue = Queue::load($arg);
  return $queue && $queue
    ->getBackendId() === 'database';
}