public function SessionKeyExists::__construct in Rules Session Variables 2.0.x
Same name and namespace in other branches
- 2.x src/Plugin/Condition/SessionKeyExists.php \Drupal\rules_session_vars\Plugin\Condition\SessionKeyExists::__construct()
Constructor for SessionKeyExists.
Parameters
array $configuration: The configuration.
string $plugin_id: The plugin ID.
mixed $plugin_definition: The plugin definition.
\Symfony\Component\HttpFoundation\Request|null $request: The request.
File
- src/
Plugin/ Condition/ SessionKeyExists.php, line 46
Class
- SessionKeyExists
- Provides a 'Session key exists' condition.
Namespace
Drupal\rules_session_vars\Plugin\ConditionCode
public function __construct(array $configuration, $plugin_id, $plugin_definition, Request $request = NULL) {
parent::__construct($configuration, $plugin_id, $plugin_definition);
$this->session = $request ? $request
->getSession() : NULL;
}