@@ -23,7 +23,7 @@ |
||
| 23 | 23 | */ |
| 24 | 24 | public function visitState($name, array $attributes) |
| 25 | 25 | { |
| 26 | - if (! isset($this->structure[$name])) { |
|
| 26 | + if (!isset($this->structure[$name])) { |
|
| 27 | 27 | $this->structure[$name] = []; |
| 28 | 28 | } |
| 29 | 29 | |
@@ -19,7 +19,7 @@ |
||
| 19 | 19 | */ |
| 20 | 20 | public function __construct(EventDispatcherInterface $dispatcher = null) |
| 21 | 21 | { |
| 22 | - if (! $dispatcher) { |
|
| 22 | + if (!$dispatcher) { |
|
| 23 | 23 | $dispatcher = new EventDispatcher(); |
| 24 | 24 | } |
| 25 | 25 | $this->dispatcher = $dispatcher; |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | $transition = new ReadOnlyTransition($this->transitions[$name]['to']); |
| 50 | 50 | } |
| 51 | 51 | |
| 52 | - if (! $transition) { |
|
| 52 | + if (!$transition) { |
|
| 53 | 53 | throw NotFoundException::transitionNotFound($name); |
| 54 | 54 | } |
| 55 | 55 | |
@@ -77,7 +77,7 @@ discard block |
||
| 77 | 77 | private function addAttributes($state, array $attributes) |
| 78 | 78 | { |
| 79 | 79 | array_map( |
| 80 | - function ($attribute) use ($state) { |
|
| 80 | + function($attribute) use ($state) { |
|
| 81 | 81 | $this->addAttribute($state, $attribute); |
| 82 | 82 | }, |
| 83 | 83 | $attributes |
@@ -111,7 +111,7 @@ discard block |
||
| 111 | 111 | { |
| 112 | 112 | Assert::string($state); |
| 113 | 113 | Assert::string($attribute); |
| 114 | - if (! $this->hasState($state)) { |
|
| 114 | + if (!$this->hasState($state)) { |
|
| 115 | 115 | return false; |
| 116 | 116 | } |
| 117 | 117 | |
@@ -59,7 +59,7 @@ discard block |
||
| 59 | 59 | */ |
| 60 | 60 | public function transit($transitionName, $context, TransitionCallback $callback = null) |
| 61 | 61 | { |
| 62 | - if (! $callback) { |
|
| 62 | + if (!$callback) { |
|
| 63 | 63 | $callback = new AlwaysThrowExceptionOnFailure(); |
| 64 | 64 | } |
| 65 | 65 | |
@@ -74,7 +74,7 @@ discard block |
||
| 74 | 74 | |
| 75 | 75 | $newState = $transition->getDestinationState(); |
| 76 | 76 | $allowed = $this->states->transitionStartsFrom($transitionName, $this->currentState); |
| 77 | - if (! $allowed) { |
|
| 77 | + if (!$allowed) { |
|
| 78 | 78 | $exception = InvalidStateTransitionException::notAllowedTransition( |
| 79 | 79 | $transitionName, |
| 80 | 80 | $context, |
@@ -110,7 +110,7 @@ discard block |
||
| 110 | 110 | public function isInState($stateName) |
| 111 | 111 | { |
| 112 | 112 | Assert::string($stateName); |
| 113 | - if (! $this->states->hasState($stateName)) { |
|
| 113 | + if (!$this->states->hasState($stateName)) { |
|
| 114 | 114 | throw NotFoundException::stateNotFound($stateName); |
| 115 | 115 | } |
| 116 | 116 | |