Passed
Push — develop ( b2a03f...b2a56a )
by Портнов
04:59 queued 11s
created
src/PBXCoreREST/Providers/ResponseProvider.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@
 block discarded – undo
30 30
     {
31 31
         $di->setShared(
32 32
             self::SERVICE_NAME,
33
-            function () {
33
+            function() {
34 34
                 $response = new Response();
35 35
 
36 36
                 /**
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,8 @@
 block discarded – undo
30 30
     {
31 31
         $di->setShared(
32 32
             self::SERVICE_NAME,
33
-            function () {
33
+            function ()
34
+            {
34 35
                 $response = new Response();
35 36
 
36 37
                 /**
Please login to merge, or discard this patch.
src/PBXCoreREST/Providers/BeanstalkConnectionProvider.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@
 block discarded – undo
33 33
     {
34 34
         $di->setShared(
35 35
             self::SERVICE_NAME,
36
-            function () {
36
+            function() {
37 37
                 return new BeanstalkClient(WorkerApiCommands::class);
38 38
             }
39 39
         );
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -33,7 +33,8 @@
 block discarded – undo
33 33
     {
34 34
         $di->setShared(
35 35
             self::SERVICE_NAME,
36
-            function () {
36
+            function ()
37
+            {
37 38
                 return new BeanstalkClient(WorkerApiCommands::class);
38 39
             }
39 40
         );
Please login to merge, or discard this patch.
src/PBXCoreREST/Providers/DispatcherProvider.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@
 block discarded – undo
35 35
     {
36 36
         $di->setShared(
37 37
             self::SERVICE_NAME,
38
-            function () {
38
+            function() {
39 39
                 // Create a events manager
40 40
                 $eventsManager = new EventsManager();
41 41
                 $dispatcher = new Dispatcher();
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -35,7 +35,8 @@
 block discarded – undo
35 35
     {
36 36
         $di->setShared(
37 37
             self::SERVICE_NAME,
38
-            function () {
38
+            function ()
39
+            {
39 40
                 // Create a events manager
40 41
                 $eventsManager = new EventsManager();
41 42
                 $dispatcher = new Dispatcher();
Please login to merge, or discard this patch.
src/Common/Models/FirewallRules.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -129,14 +129,14 @@
 block discarded – undo
129 129
 
130 130
         //Add modules firewall rules
131 131
         $di = Di::getDefault();
132
-        if ($di!==null) {
132
+        if ($di !== null) {
133 133
             $pbxConfModules = $di->get('pbxConfModules');
134
-            foreach ($pbxConfModules as $pbxConfModule){
134
+            foreach ($pbxConfModules as $pbxConfModule) {
135 135
                 $additionalRules = $pbxConfModule->getDefaultFirewallRules();
136
-                if ($additionalRules!==[]){
136
+                if ($additionalRules !== []) {
137 137
                     $additionalRules = array_change_key_case($additionalRules, CASE_UPPER);
138
-                    foreach ($additionalRules as $key=>$rule){
139
-                        $template[$key]=$rule;
138
+                    foreach ($additionalRules as $key=>$rule) {
139
+                        $template[$key] = $rule;
140 140
                     }
141 141
                 }
142 142
             }
Please login to merge, or discard this patch.
src/Common/Providers/NatsConnectionProvider.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
         $gnatsConfig = $di->getShared('config')->get('gnats');
35 35
         $di->setShared(
36 36
             self::SERVICE_NAME,
37
-            function () use ($gnatsConfig) {
37
+            function() use ($gnatsConfig) {
38 38
                 $connectionOptions = new NatsConnectionOptions();
39 39
                 $host              = $gnatsConfig->host;
40 40
                 $port              = $gnatsConfig->port;
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,8 @@
 block discarded – undo
34 34
         $gnatsConfig = $di->getShared('config')->get('gnats');
35 35
         $di->setShared(
36 36
             self::SERVICE_NAME,
37
-            function () use ($gnatsConfig) {
37
+            function () use ($gnatsConfig)
38
+            {
38 39
                 $connectionOptions = new NatsConnectionOptions();
39 40
                 $host              = $gnatsConfig->host;
40 41
                 $port              = $gnatsConfig->port;
Please login to merge, or discard this patch.
src/Common/Providers/UrlProvider.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@
 block discarded – undo
40 40
         $baseUri = $di->getShared('config')->path('adminApplication.baseUri');
41 41
         $di->setShared(
42 42
             self::SERVICE_NAME,
43
-            function () use ($baseUri) {
43
+            function() use ($baseUri) {
44 44
                 $url = new Url();
45 45
                 $url->setBaseUri($baseUri);
46 46
 
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -40,7 +40,8 @@
 block discarded – undo
40 40
         $baseUri = $di->getShared('config')->path('adminApplication.baseUri');
41 41
         $di->setShared(
42 42
             self::SERVICE_NAME,
43
-            function () use ($baseUri) {
43
+            function () use ($baseUri)
44
+            {
44 45
                 $url = new Url();
45 46
                 $url->setBaseUri($baseUri);
46 47
 
Please login to merge, or discard this patch.
src/Common/Providers/RegistryProvider.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@
 block discarded – undo
38 38
     {
39 39
         $di->setShared(
40 40
             self::SERVICE_NAME,
41
-            function () {
41
+            function() {
42 42
                 return new Registry();
43 43
             }
44 44
         );
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -38,7 +38,8 @@
 block discarded – undo
38 38
     {
39 39
         $di->setShared(
40 40
             self::SERVICE_NAME,
41
-            function () {
41
+            function ()
42
+            {
42 43
                 return new Registry();
43 44
             }
44 45
         );
Please login to merge, or discard this patch.
src/Common/Providers/AmiConnectionCommand.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
 use Phalcon\Di\DiInterface;
14 14
 use Phalcon\Di\ServiceProviderInterface;
15 15
 
16
-class AmiConnectionCommand implements ServiceProviderInterface{
16
+class AmiConnectionCommand implements ServiceProviderInterface {
17 17
 
18 18
     public const SERVICE_NAME = 'amiCommander';
19 19
     /**
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
     {
26 26
         $di->setShared(
27 27
             self::SERVICE_NAME,
28
-            function () {
28
+            function() {
29 29
                 $port   = PbxSettings::getValueByKey('AMIPort');
30 30
                 $am     = new AsteriskManager();
31 31
                 $am->connect("127.0.0.1:{$port}", null, null, 'off');
Please login to merge, or discard this patch.
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,7 +13,8 @@  discard block
 block discarded – undo
13 13
 use Phalcon\Di\DiInterface;
14 14
 use Phalcon\Di\ServiceProviderInterface;
15 15
 
16
-class AmiConnectionCommand implements ServiceProviderInterface{
16
+class AmiConnectionCommand implements ServiceProviderInterface
17
+{
17 18
 
18 19
     public const SERVICE_NAME = 'amiCommander';
19 20
     /**
@@ -25,7 +26,8 @@  discard block
 block discarded – undo
25 26
     {
26 27
         $di->setShared(
27 28
             self::SERVICE_NAME,
28
-            function () {
29
+            function ()
30
+            {
29 31
                 $port   = PbxSettings::getValueByKey('AMIPort');
30 32
                 $am     = new AsteriskManager();
31 33
                 $am->connect("127.0.0.1:{$port}", null, null, 'off');
Please login to merge, or discard this patch.
src/Common/Providers/SessionReadOnlyProvider.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -32,13 +32,13 @@
 block discarded – undo
32 32
         $phpSessionDir = $di->getShared('config')->path('www.phpSessionDir');
33 33
         $di->setShared(
34 34
             self::SERVICE_NAME,
35
-            function () use ($phpSessionDir) {
36
-                if ( ! is_array($_COOKIE) || ! array_key_exists(session_name(), $_COOKIE)) {
35
+            function() use ($phpSessionDir) {
36
+                if (!is_array($_COOKIE) || !array_key_exists(session_name(), $_COOKIE)) {
37 37
                     return null;
38 38
                 }
39 39
                 $session_name = preg_replace('/[^\da-z]/i', '', $_COOKIE[session_name()]);
40
-                $session_file = $phpSessionDir . '/sess_' . $session_name;
41
-                if ( ! file_exists($session_file)) {
40
+                $session_file = $phpSessionDir.'/sess_'.$session_name;
41
+                if (!file_exists($session_file)) {
42 42
                     return null;
43 43
                 }
44 44
 
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -32,7 +32,8 @@
 block discarded – undo
32 32
         $phpSessionDir = $di->getShared('config')->path('www.phpSessionDir');
33 33
         $di->setShared(
34 34
             self::SERVICE_NAME,
35
-            function () use ($phpSessionDir) {
35
+            function () use ($phpSessionDir)
36
+            {
36 37
                 if ( ! is_array($_COOKIE) || ! array_key_exists(session_name(), $_COOKIE)) {
37 38
                     return null;
38 39
                 }
Please login to merge, or discard this patch.