You are here

public function Event::isDatalayerMethod in GA Push 8

Check if selected method is datalayer.

Return value

bool Is datalayer method?

1 call to Event::isDatalayerMethod()
Event::doExecute in src/Plugin/RulesAction/Event.php
Executes the action with the given context.

File

src/Plugin/RulesAction/Event.php, line 80

Class

Event
Provides a 'Ga Push Event' action.

Namespace

Drupal\ga_push\Plugin\RulesAction

Code

public function isDatalayerMethod() {
  $method = $this
    ->getContextValue('method');
  return $method == GA_PUSH_METHOD_DATALAYER_JS || $this
    ->getDefaultMethod() == GA_PUSH_METHOD_DATALAYER_JS;
}