Passed
Push — develop ( 83b649...63947e )
by Johnny
02:08
created
src/Rivescript.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
     {
30 30
         parent::__construct();
31 31
 
32
-        include __DIR__ . '/bootstrap.php';
32
+        include __DIR__.'/bootstrap.php';
33 33
     }
34 34
 
35 35
     /**
Please login to merge, or discard this patch.
src/Cortex/Brain.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -61,7 +61,7 @@
 block discarded – undo
61 61
                     continue;
62 62
                 }
63 63
 
64
-                $commands->each(function ($command) use ($node) {
64
+                $commands->each(function($command) use ($node) {
65 65
                     $class = "\\Axiom\\Rivescript\\Cortex\\Commands\\$command";
66 66
                     $commandClass = new $class();
67 67
                     $commandClass->parse($node);
Please login to merge, or discard this patch.
src/Cortex/ContentLoader/ContentLoader.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -50,7 +50,7 @@
 block discarded – undo
50 50
         }
51 51
 
52 52
         if (stream_wrapper_register($this->name, ContentStream::class)) {
53
-            $this->stream = fopen($this->name . "://input", "r+");
53
+            $this->stream = fopen($this->name."://input", "r+");
54 54
         }
55 55
 
56 56
         if (is_resource($this->stream) === false) {
Please login to merge, or discard this patch.
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -111,8 +111,9 @@
 block discarded – undo
111 111
     public function loadDirectory(string $path)
112 112
     {
113 113
         foreach (new DirectoryIterator($path) as $file) {
114
-            if ($file->isDot())
115
-                continue;
114
+            if ($file->isDot()) {
115
+                            continue;
116
+            }
116 117
 
117 118
             $this->loadFile($file->getPathname());
118 119
         }
Please login to merge, or discard this patch.
src/Cortex/ContentLoader/ContentStream.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
      */
77 77
     public function stream_read(int $count): string
78 78
     {
79
-        $p =& $this->position;
79
+        $p = & $this->position;
80 80
         $ret = substr($this->content, $p, $count);
81 81
         $p += strlen($ret);
82 82
         return $ret;
@@ -91,10 +91,10 @@  discard block
 block discarded – undo
91 91
      */
92 92
     public function stream_write(string $data): int
93 93
     {
94
-        $v =& $this->content;
94
+        $v = & $this->content;
95 95
         $l = strlen($data);
96
-        $p =& $this->position;
97
-        $v = substr($v, 0, $p) . $data . substr($v, $p += $l);
96
+        $p = & $this->position;
97
+        $v = substr($v, 0, $p).$data.substr($v, $p += $l);
98 98
         return $l;
99 99
     }
100 100
 
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
     public function stream_seek(int $offset, int $whence = SEEK_SET): bool
133 133
     {
134 134
         $l = strlen($this->content);
135
-        $p =& $this->position;
135
+        $p = & $this->position;
136 136
         switch ($whence) {
137 137
             case SEEK_SET:
138 138
                 $newPos = $offset;
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -147,7 +147,9 @@
 block discarded – undo
147 147
                 return false;
148 148
         }
149 149
         $ret = ($newPos >= 0 && $newPos <= $l);
150
-        if ($ret) $p = $newPos;
150
+        if ($ret) {
151
+            $p = $newPos;
152
+        }
151 153
         return $ret;
152 154
     }
153 155
 }
Please login to merge, or discard this patch.