Passed
Pull Request — master (#277)
by Kirill
03:52 queued 48s
created
src/Framework/Http/Middleware/ErrorHandlerMiddleware.php 2 patches
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
         RendererInterface $renderer,
58 58
         ResponseFactoryInterface $responseFactory,
59 59
         ContainerInterface $container
60
-    ) {
60
+    ){
61 61
         $this->suppressErrors = $suppressErrors;
62 62
         $this->renderer = $renderer;
63 63
         $this->responseFactory = $responseFactory;
@@ -71,22 +71,22 @@  discard block
 block discarded – undo
71 71
      */
72 72
     public function process(Request $request, Handler $handler): Response
73 73
     {
74
-        try {
74
+        try{
75 75
             return $handler->handle($request);
76
-        } catch (ClientException | RouterException $e) {
77
-            if ($e instanceof ClientException) {
76
+        }catch (ClientException | RouterException $e){
77
+            if ($e instanceof ClientException){
78 78
                 $code = $e->getCode();
79
-            } else {
79
+            }else{
80 80
                 $code = 404;
81 81
             }
82
-        } catch (\Throwable $e) {
82
+        }catch (\Throwable $e){
83 83
             $snapshotter = $this->getOptional(SnapshotterInterface::class);
84
-            if ($snapshotter !== null) {
84
+            if ($snapshotter !== null){
85 85
                 /** @var SnapshotterInterface $snapshotter */
86 86
                 $snapshotter->register($e);
87 87
             }
88 88
 
89
-            if (!$this->suppressErrors) {
89
+            if (!$this->suppressErrors){
90 90
                 return $this->renderError($request, $e);
91 91
             }
92 92
 
@@ -109,7 +109,7 @@  discard block
 block discarded – undo
109 109
     {
110 110
         $response = $this->responseFactory->createResponse(500);
111 111
 
112
-        if ($request->getHeaderLine('Accept') == 'application/json') {
112
+        if ($request->getHeaderLine('Accept') == 'application/json'){
113 113
             $response = $response->withHeader('Content-Type', 'application/json');
114 114
             $handler = new JsonHandler();
115 115
             $response->getBody()->write(
@@ -121,10 +121,10 @@  discard block
 block discarded – undo
121 121
                     )
122 122
                 )
123 123
             );
124
-        } else {
124
+        }else{
125 125
             $handler = new HtmlHandler();
126 126
             $state = $this->getOptional(StateInterface::class);
127
-            if ($state !== null) {
127
+            if ($state !== null){
128 128
                 $handler = $handler->withState($state);
129 129
             }
130 130
 
@@ -160,9 +160,9 @@  discard block
 block discarded – undo
160 160
      */
161 161
     private function getOptional(string $class)
162 162
     {
163
-        try {
163
+        try{
164 164
             return $this->container->get($class);
165
-        } catch (\Throwable | ContainerExceptionInterface $se) {
165
+        }catch (\Throwable | ContainerExceptionInterface $se){
166 166
             return null;
167 167
         }
168 168
     }
Please login to merge, or discard this patch.
Braces   +29 added lines, -12 removed lines patch added patch discarded remove patch
@@ -71,22 +71,32 @@  discard block
 block discarded – undo
71 71
      */
72 72
     public function process(Request $request, Handler $handler): Response
73 73
     {
74
-        try {
74
+        try
75
+        {
75 76
             return $handler->handle($request);
76
-        } catch (ClientException | RouterException $e) {
77
-            if ($e instanceof ClientException) {
77
+        }
78
+        catch (ClientException | RouterException $e)
79
+        {
80
+            if ($e instanceof ClientException)
81
+            {
78 82
                 $code = $e->getCode();
79
-            } else {
83
+            }
84
+            else
85
+            {
80 86
                 $code = 404;
81 87
             }
82
-        } catch (\Throwable $e) {
88
+        }
89
+        catch (\Throwable $e)
90
+        {
83 91
             $snapshotter = $this->getOptional(SnapshotterInterface::class);
84
-            if ($snapshotter !== null) {
92
+            if ($snapshotter !== null)
93
+            {
85 94
                 /** @var SnapshotterInterface $snapshotter */
86 95
                 $snapshotter->register($e);
87 96
             }
88 97
 
89
-            if (!$this->suppressErrors) {
98
+            if (!$this->suppressErrors)
99
+            {
90 100
                 return $this->renderError($request, $e);
91 101
             }
92 102
 
@@ -109,7 +119,8 @@  discard block
 block discarded – undo
109 119
     {
110 120
         $response = $this->responseFactory->createResponse(500);
111 121
 
112
-        if ($request->getHeaderLine('Accept') == 'application/json') {
122
+        if ($request->getHeaderLine('Accept') == 'application/json')
123
+        {
113 124
             $response = $response->withHeader('Content-Type', 'application/json');
114 125
             $handler = new JsonHandler();
115 126
             $response->getBody()->write(
@@ -121,10 +132,13 @@  discard block
 block discarded – undo
121 132
                     )
122 133
                 )
123 134
             );
124
-        } else {
135
+        }
136
+        else
137
+        {
125 138
             $handler = new HtmlHandler();
126 139
             $state = $this->getOptional(StateInterface::class);
127
-            if ($state !== null) {
140
+            if ($state !== null)
141
+            {
128 142
                 $handler = $handler->withState($state);
129 143
             }
130 144
 
@@ -160,9 +174,12 @@  discard block
 block discarded – undo
160 174
      */
161 175
     private function getOptional(string $class)
162 176
     {
163
-        try {
177
+        try
178
+        {
164 179
             return $this->container->get($class);
165
-        } catch (\Throwable | ContainerExceptionInterface $se) {
180
+        }
181
+        catch (\Throwable | ContainerExceptionInterface $se)
182
+        {
166 183
             return null;
167 184
         }
168 185
     }
Please login to merge, or discard this patch.
src/Framework/Jobs/JobDispatcher.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
         EnvironmentInterface $env,
40 40
         FinalizerInterface $finalizer,
41 41
         ContainerInterface $container
42
-    ) {
42
+    ){
43 43
         $this->env = $env;
44 44
         $this->finalizer = $finalizer;
45 45
         $this->container = $container;
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
         $consumer->serve(
71 71
             $worker,
72 72
             function (\Throwable $e = null): void {
73
-                if ($e !== null) {
73
+                if ($e !== null){
74 74
                     $this->handleException($e);
75 75
                 }
76 76
 
@@ -84,9 +84,9 @@  discard block
 block discarded – undo
84 84
      */
85 85
     protected function handleException(\Throwable $e): void
86 86
     {
87
-        try {
87
+        try{
88 88
             $this->container->get(SnapshotterInterface::class)->register($e);
89
-        } catch (\Throwable | ContainerExceptionInterface $se) {
89
+        }catch (\Throwable | ContainerExceptionInterface $se){
90 90
             // no need to notify when unable to register an exception
91 91
         }
92 92
     }
Please login to merge, or discard this patch.
Braces   +7 added lines, -3 removed lines patch added patch discarded remove patch
@@ -70,7 +70,8 @@  discard block
 block discarded – undo
70 70
         $consumer->serve(
71 71
             $worker,
72 72
             function (\Throwable $e = null): void {
73
-                if ($e !== null) {
73
+                if ($e !== null)
74
+                {
74 75
                     $this->handleException($e);
75 76
                 }
76 77
 
@@ -84,9 +85,12 @@  discard block
 block discarded – undo
84 85
      */
85 86
     protected function handleException(\Throwable $e): void
86 87
     {
87
-        try {
88
+        try
89
+        {
88 90
             $this->container->get(SnapshotterInterface::class)->register($e);
89
-        } catch (\Throwable | ContainerExceptionInterface $se) {
91
+        }
92
+        catch (\Throwable | ContainerExceptionInterface $se)
93
+        {
90 94
             // no need to notify when unable to register an exception
91 95
         }
92 96
     }
Please login to merge, or discard this patch.
src/Framework/Jobs/JobQueue.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -42,12 +42,12 @@
 block discarded – undo
42 42
      */
43 43
     public function push(string $jobType, array $payload = [], Options $options = null): string
44 44
     {
45
-        if ($options === null) {
45
+        if ($options === null){
46 46
             $options = new Options();
47 47
         }
48 48
 
49 49
         $pipeline = $this->registry->getPipeline($jobType);
50
-        if ($pipeline !== null && $options->getPipeline() === null) {
50
+        if ($pipeline !== null && $options->getPipeline() === null){
51 51
             $options = $options->withPipeline($pipeline);
52 52
         }
53 53
 
Please login to merge, or discard this patch.
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -42,12 +42,14 @@
 block discarded – undo
42 42
      */
43 43
     public function push(string $jobType, array $payload = [], Options $options = null): string
44 44
     {
45
-        if ($options === null) {
45
+        if ($options === null)
46
+        {
46 47
             $options = new Options();
47 48
         }
48 49
 
49 50
         $pipeline = $this->registry->getPipeline($jobType);
50
-        if ($pipeline !== null && $options->getPipeline() === null) {
51
+        if ($pipeline !== null && $options->getPipeline() === null)
52
+        {
51 53
             $options = $options->withPipeline($pipeline);
52 54
         }
53 55
 
Please login to merge, or discard this patch.
src/Framework/Jobs/JobRegistry.php 2 patches
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
         ContainerInterface $container,
46 46
         HandlerRegistryInterface $handlers,
47 47
         SerializerRegistryInterface $serializers
48
-    ) {
48
+    ){
49 49
         $this->container = $container;
50 50
         $this->fallbackHandlers = $handlers;
51 51
         $this->fallbackSerializers = $serializers;
@@ -66,8 +66,8 @@  discard block
 block discarded – undo
66 66
      */
67 67
     public function getHandler(string $jobType): HandlerInterface
68 68
     {
69
-        if (isset($this->handlers[$jobType])) {
70
-            if ($this->handlers[$jobType] instanceof HandlerInterface) {
69
+        if (isset($this->handlers[$jobType])){
70
+            if ($this->handlers[$jobType] instanceof HandlerInterface){
71 71
                 return $this->handlers[$jobType];
72 72
             }
73 73
 
@@ -92,20 +92,20 @@  discard block
 block discarded – undo
92 92
      */
93 93
     public function getSerializer(string $jobType): SerializerInterface
94 94
     {
95
-        if (isset($this->serializers[$jobType])) {
96
-            if ($this->serializers[$jobType] instanceof SerializerInterface) {
95
+        if (isset($this->serializers[$jobType])){
96
+            if ($this->serializers[$jobType] instanceof SerializerInterface){
97 97
                 return $this->serializers[$jobType];
98 98
             }
99 99
 
100 100
             return $this->container->get($this->serializers[$jobType]);
101 101
         }
102 102
 
103
-        if (!isset($this->handlers[$jobType])) {
103
+        if (!isset($this->handlers[$jobType])){
104 104
             return $this->fallbackSerializers->getSerializer($jobType);
105 105
         }
106 106
 
107 107
         $handler = $this->getHandler($jobType);
108
-        if ($handler instanceof SerializerInterface) {
108
+        if ($handler instanceof SerializerInterface){
109 109
             return $handler;
110 110
         }
111 111
 
Please login to merge, or discard this patch.
Braces   +12 added lines, -6 removed lines patch added patch discarded remove patch
@@ -66,8 +66,10 @@  discard block
 block discarded – undo
66 66
      */
67 67
     public function getHandler(string $jobType): HandlerInterface
68 68
     {
69
-        if (isset($this->handlers[$jobType])) {
70
-            if ($this->handlers[$jobType] instanceof HandlerInterface) {
69
+        if (isset($this->handlers[$jobType]))
70
+        {
71
+            if ($this->handlers[$jobType] instanceof HandlerInterface)
72
+            {
71 73
                 return $this->handlers[$jobType];
72 74
             }
73 75
 
@@ -92,20 +94,24 @@  discard block
 block discarded – undo
92 94
      */
93 95
     public function getSerializer(string $jobType): SerializerInterface
94 96
     {
95
-        if (isset($this->serializers[$jobType])) {
96
-            if ($this->serializers[$jobType] instanceof SerializerInterface) {
97
+        if (isset($this->serializers[$jobType]))
98
+        {
99
+            if ($this->serializers[$jobType] instanceof SerializerInterface)
100
+            {
97 101
                 return $this->serializers[$jobType];
98 102
             }
99 103
 
100 104
             return $this->container->get($this->serializers[$jobType]);
101 105
         }
102 106
 
103
-        if (!isset($this->handlers[$jobType])) {
107
+        if (!isset($this->handlers[$jobType]))
108
+        {
104 109
             return $this->fallbackSerializers->getSerializer($jobType);
105 110
         }
106 111
 
107 112
         $handler = $this->getHandler($jobType);
108
-        if ($handler instanceof SerializerInterface) {
113
+        if ($handler instanceof SerializerInterface)
114
+        {
109 115
             return $handler;
110 116
         }
111 117
 
Please login to merge, or discard this patch.
src/Framework/Console/ConsoleDispatcher.php 2 patches
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
         EnvironmentInterface $env,
49 49
         FinalizerInterface $finalizer,
50 50
         ContainerInterface $container
51
-    ) {
51
+    ){
52 52
         $this->env = $env;
53 53
         $this->finalizer = $finalizer;
54 54
         $this->container = $container;
@@ -79,13 +79,13 @@  discard block
 block discarded – undo
79 79
         /** @var Console $console */
80 80
         $console = $this->container->get(Console::class);
81 81
 
82
-        try {
82
+        try{
83 83
             return $console->start($input ?? new ArgvInput(), $output);
84
-        } catch (Throwable $e) {
84
+        }catch (Throwable $e){
85 85
             $this->handleException($e, $output);
86 86
 
87 87
             return 255;
88
-        } finally {
88
+        }finally{
89 89
             $listener->disable();
90 90
             $this->finalizer->finalize(false);
91 91
         }
@@ -97,9 +97,9 @@  discard block
 block discarded – undo
97 97
      */
98 98
     protected function handleException(Throwable $e, OutputInterface $output): void
99 99
     {
100
-        try {
100
+        try{
101 101
             $this->container->get(SnapshotterInterface::class)->register($e);
102
-        } catch (Throwable | ContainerExceptionInterface $se) {
102
+        }catch (Throwable | ContainerExceptionInterface $se){
103 103
             // no need to notify when unable to register an exception
104 104
         }
105 105
 
@@ -114,11 +114,11 @@  discard block
 block discarded – undo
114 114
      */
115 115
     private function mapVerbosity(OutputInterface $output): int
116 116
     {
117
-        if ($output->isDebug()) {
117
+        if ($output->isDebug()){
118 118
             return ConsoleHandler::VERBOSITY_DEBUG;
119 119
         }
120 120
 
121
-        if ($output->isVeryVerbose()) {
121
+        if ($output->isVeryVerbose()){
122 122
             return ConsoleHandler::VERBOSITY_VERBOSE;
123 123
         }
124 124
 
Please login to merge, or discard this patch.
Braces   +17 added lines, -7 removed lines patch added patch discarded remove patch
@@ -79,13 +79,18 @@  discard block
 block discarded – undo
79 79
         /** @var Console $console */
80 80
         $console = $this->container->get(Console::class);
81 81
 
82
-        try {
82
+        try
83
+        {
83 84
             return $console->start($input ?? new ArgvInput(), $output);
84
-        } catch (Throwable $e) {
85
+        }
86
+        catch (Throwable $e)
87
+        {
85 88
             $this->handleException($e, $output);
86 89
 
87 90
             return 255;
88
-        } finally {
91
+        }
92
+        finally
93
+        {
89 94
             $listener->disable();
90 95
             $this->finalizer->finalize(false);
91 96
         }
@@ -97,9 +102,12 @@  discard block
 block discarded – undo
97 102
      */
98 103
     protected function handleException(Throwable $e, OutputInterface $output): void
99 104
     {
100
-        try {
105
+        try
106
+        {
101 107
             $this->container->get(SnapshotterInterface::class)->register($e);
102
-        } catch (Throwable | ContainerExceptionInterface $se) {
108
+        }
109
+        catch (Throwable | ContainerExceptionInterface $se)
110
+        {
103 111
             // no need to notify when unable to register an exception
104 112
         }
105 113
 
@@ -114,11 +122,13 @@  discard block
 block discarded – undo
114 122
      */
115 123
     private function mapVerbosity(OutputInterface $output): int
116 124
     {
117
-        if ($output->isDebug()) {
125
+        if ($output->isDebug())
126
+        {
118 127
             return ConsoleHandler::VERBOSITY_DEBUG;
119 128
         }
120 129
 
121
-        if ($output->isVeryVerbose()) {
130
+        if ($output->isVeryVerbose())
131
+        {
122 132
             return ConsoleHandler::VERBOSITY_VERBOSE;
123 133
         }
124 134
 
Please login to merge, or discard this patch.
src/Framework/Console/CommandLocator.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,8 +37,8 @@
 block discarded – undo
37 37
     public function locateCommands(): array
38 38
     {
39 39
         $commands = [];
40
-        foreach ($this->classes->getClasses(SymfonyCommand::class) as $class) {
41
-            if ($class->isAbstract()) {
40
+        foreach ($this->classes->getClasses(SymfonyCommand::class) as $class){
41
+            if ($class->isAbstract()){
42 42
                 continue;
43 43
             }
44 44
 
Please login to merge, or discard this patch.
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,8 +37,10 @@
 block discarded – undo
37 37
     public function locateCommands(): array
38 38
     {
39 39
         $commands = [];
40
-        foreach ($this->classes->getClasses(SymfonyCommand::class) as $class) {
41
-            if ($class->isAbstract()) {
40
+        foreach ($this->classes->getClasses(SymfonyCommand::class) as $class)
41
+        {
42
+            if ($class->isAbstract())
43
+            {
42 44
                 continue;
43 45
             }
44 46
 
Please login to merge, or discard this patch.
src/Framework/Console/Logger/DebugListener.php 2 patches
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -51,11 +51,11 @@  discard block
 block discarded – undo
51 51
      */
52 52
     public function __invoke(LogEvent $event): void
53 53
     {
54
-        if (empty($this->output)) {
54
+        if (empty($this->output)){
55 55
             return;
56 56
         }
57 57
 
58
-        if ($this->output->getVerbosity() < OutputInterface::VERBOSITY_VERY_VERBOSE) {
58
+        if ($this->output->getVerbosity() < OutputInterface::VERBOSITY_VERY_VERBOSE){
59 59
             return;
60 60
         }
61 61
 
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
      */
94 94
     public function enable(): self
95 95
     {
96
-        if (!empty($this->listenerRegistry)) {
96
+        if (!empty($this->listenerRegistry)){
97 97
             $this->listenerRegistry->addListener($this);
98 98
         }
99 99
 
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
      */
108 108
     public function disable(): self
109 109
     {
110
-        if (!empty($this->listenerRegistry)) {
110
+        if (!empty($this->listenerRegistry)){
111 111
             $this->listenerRegistry->removeListener($this);
112 112
         }
113 113
 
@@ -130,13 +130,13 @@  discard block
 block discarded – undo
130 130
      */
131 131
     private function getChannel(string $channel): string
132 132
     {
133
-        if (!class_exists($channel, false)) {
133
+        if (!class_exists($channel, false)){
134 134
             return "[{$channel}]";
135 135
         }
136 136
 
137
-        try {
137
+        try{
138 138
             $reflection = new \ReflectionClass($channel);
139
-        } catch (\ReflectionException $e) {
139
+        }catch (\ReflectionException $e){
140 140
             return $channel;
141 141
         }
142 142
 
@@ -150,10 +150,10 @@  discard block
 block discarded – undo
150 150
      */
151 151
     private function getMessage(bool $decorated, string $message): string
152 152
     {
153
-        if (!$decorated) {
153
+        if (!$decorated){
154 154
             return $message;
155 155
         }
156 156
 
157
-        return Color::GRAY . $message . Color::RESET;
157
+        return Color::GRAY.$message.Color::RESET;
158 158
     }
159 159
 }
Please login to merge, or discard this patch.
Braces   +17 added lines, -8 removed lines patch added patch discarded remove patch
@@ -51,11 +51,13 @@  discard block
 block discarded – undo
51 51
      */
52 52
     public function __invoke(LogEvent $event): void
53 53
     {
54
-        if (empty($this->output)) {
54
+        if (empty($this->output))
55
+        {
55 56
             return;
56 57
         }
57 58
 
58
-        if ($this->output->getVerbosity() < OutputInterface::VERBOSITY_VERY_VERBOSE) {
59
+        if ($this->output->getVerbosity() < OutputInterface::VERBOSITY_VERY_VERBOSE)
60
+        {
59 61
             return;
60 62
         }
61 63
 
@@ -93,7 +95,8 @@  discard block
 block discarded – undo
93 95
      */
94 96
     public function enable(): self
95 97
     {
96
-        if (!empty($this->listenerRegistry)) {
98
+        if (!empty($this->listenerRegistry))
99
+        {
97 100
             $this->listenerRegistry->addListener($this);
98 101
         }
99 102
 
@@ -107,7 +110,8 @@  discard block
 block discarded – undo
107 110
      */
108 111
     public function disable(): self
109 112
     {
110
-        if (!empty($this->listenerRegistry)) {
113
+        if (!empty($this->listenerRegistry))
114
+        {
111 115
             $this->listenerRegistry->removeListener($this);
112 116
         }
113 117
 
@@ -130,13 +134,17 @@  discard block
 block discarded – undo
130 134
      */
131 135
     private function getChannel(string $channel): string
132 136
     {
133
-        if (!class_exists($channel, false)) {
137
+        if (!class_exists($channel, false))
138
+        {
134 139
             return "[{$channel}]";
135 140
         }
136 141
 
137
-        try {
142
+        try
143
+        {
138 144
             $reflection = new \ReflectionClass($channel);
139
-        } catch (\ReflectionException $e) {
145
+        }
146
+        catch (\ReflectionException $e)
147
+        {
140 148
             return $channel;
141 149
         }
142 150
 
@@ -150,7 +158,8 @@  discard block
 block discarded – undo
150 158
      */
151 159
     private function getMessage(bool $decorated, string $message): string
152 160
     {
153
-        if (!$decorated) {
161
+        if (!$decorated)
162
+        {
154 163
             return $message;
155 164
         }
156 165
 
Please login to merge, or discard this patch.
src/Framework/Console/Sequence/RuntimeDirectory.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
 
46 46
         $runtimeDirectory = $this->dirs->get('runtime');
47 47
 
48
-        if (!$this->files->exists($runtimeDirectory)) {
48
+        if (!$this->files->exists($runtimeDirectory)){
49 49
             $this->files->ensureDirectory($runtimeDirectory);
50 50
             $output->writeln('<comment>created</comment>');
51 51
             return;
@@ -53,11 +53,11 @@  discard block
 block discarded – undo
53 53
         $output->writeln('<info>exists</info>');
54 54
 
55 55
 
56
-        foreach ($this->files->getFiles($runtimeDirectory) as $filename) {
57
-            try {
56
+        foreach ($this->files->getFiles($runtimeDirectory) as $filename){
57
+            try{
58 58
                 $this->files->setPermissions($filename, FilesInterface::RUNTIME);
59 59
                 $this->files->setPermissions(dirname($filename), FilesInterface::RUNTIME);
60
-            } catch (\Throwable $e) {
60
+            }catch (\Throwable $e){
61 61
                 // @codeCoverageIgnoreStart
62 62
                 $output->writeln(
63 63
                     sprintf(
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
                 // @codeCoverageIgnoreEnd
71 71
             }
72 72
 
73
-            if ($output->isVerbose()) {
73
+            if ($output->isVerbose()){
74 74
                 $output->writeln(
75 75
                     sprintf(
76 76
                         '<fg=green>[updated]</fg=green> `%s`',
Please login to merge, or discard this patch.
Braces   +11 added lines, -5 removed lines patch added patch discarded remove patch
@@ -45,7 +45,8 @@  discard block
 block discarded – undo
45 45
 
46 46
         $runtimeDirectory = $this->dirs->get('runtime');
47 47
 
48
-        if (!$this->files->exists($runtimeDirectory)) {
48
+        if (!$this->files->exists($runtimeDirectory))
49
+        {
49 50
             $this->files->ensureDirectory($runtimeDirectory);
50 51
             $output->writeln('<comment>created</comment>');
51 52
             return;
@@ -53,11 +54,15 @@  discard block
 block discarded – undo
53 54
         $output->writeln('<info>exists</info>');
54 55
 
55 56
 
56
-        foreach ($this->files->getFiles($runtimeDirectory) as $filename) {
57
-            try {
57
+        foreach ($this->files->getFiles($runtimeDirectory) as $filename)
58
+        {
59
+            try
60
+            {
58 61
                 $this->files->setPermissions($filename, FilesInterface::RUNTIME);
59 62
                 $this->files->setPermissions(dirname($filename), FilesInterface::RUNTIME);
60
-            } catch (\Throwable $e) {
63
+            }
64
+            catch (\Throwable $e)
65
+            {
61 66
                 // @codeCoverageIgnoreStart
62 67
                 $output->writeln(
63 68
                     sprintf(
@@ -70,7 +75,8 @@  discard block
 block discarded – undo
70 75
                 // @codeCoverageIgnoreEnd
71 76
             }
72 77
 
73
-            if ($output->isVerbose()) {
78
+            if ($output->isVerbose())
79
+            {
74 80
                 $output->writeln(
75 81
                     sprintf(
76 82
                         '<fg=green>[updated]</fg=green> `%s`',
Please login to merge, or discard this patch.
src/Framework/Session/SessionScope.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -124,9 +124,9 @@
 block discarded – undo
124 124
      */
125 125
     public function getActiveSession(): SessionInterface
126 126
     {
127
-        try {
127
+        try{
128 128
             return $this->container->get(SessionInterface::class);
129
-        } catch (NotFoundExceptionInterface $e) {
129
+        }catch (NotFoundExceptionInterface $e){
130 130
             throw new ScopeException(
131 131
                 'Unable to receive active session, invalid request scope',
132 132
                 $e->getCode(),
Please login to merge, or discard this patch.
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -124,9 +124,12 @@
 block discarded – undo
124 124
      */
125 125
     public function getActiveSession(): SessionInterface
126 126
     {
127
-        try {
127
+        try
128
+        {
128 129
             return $this->container->get(SessionInterface::class);
129
-        } catch (NotFoundExceptionInterface $e) {
130
+        }
131
+        catch (NotFoundExceptionInterface $e)
132
+        {
130 133
             throw new ScopeException(
131 134
                 'Unable to receive active session, invalid request scope',
132 135
                 $e->getCode(),
Please login to merge, or discard this patch.