From eb91f5679c665bf6c2891f7bac7182d1d88de9de Mon Sep 17 00:00:00 2001 From: Fatih AYDIN Date: Mon, 20 Nov 2023 14:47:42 +0300 Subject: [PATCH] refactor: Updated `$scenarioEnabled` variabled renamed to `$scenariosEnabled` --- src/Definition/MachineDefinition.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Definition/MachineDefinition.php b/src/Definition/MachineDefinition.php index 148de3d..17d17f9 100644 --- a/src/Definition/MachineDefinition.php +++ b/src/Definition/MachineDefinition.php @@ -58,7 +58,7 @@ class MachineDefinition public ?StateDefinition $initialStateDefinition = null; /** Indicates whether the scenario is enabled. */ - public bool $scenarioEnabled = false; + public bool $scenariosEnabled = false; // endregion @@ -81,12 +81,12 @@ private function __construct( public ?array $scenarios, public string $delimiter = self::STATE_DELIMITER, ) { - $this->scenarioEnabled = isset($this->config['scenario_enabled']) && $this->config['scenario_enabled'] === true; + $this->scenariosEnabled = isset($this->config['scenarios_enabled']) && $this->config['scenarios_enabled'] === true; $this->root = $this->createRootStateDefinition($config); // Checks if the scenario is enabled, and if true, creates scenario state definitions. - if ($this->scenarioEnabled) { + if ($this->scenariosEnabled) { $this->createScenarioStateDefinitions(); } @@ -277,7 +277,7 @@ public function getInitialState(EventBehavior|array $event = null): ?State */ public function getScenarioStateIfAvailable(State $state, EventBehavior|array $eventBehavior = null): ?State { - if ($this->scenarioEnabled === false) { + if ($this->scenariosEnabled === false) { return $state; }