Passed
Push — master ( 24771a...147935 )
by Pouya
01:15
created
src/ConvertToAbsolutePath.php 2 patches
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -111,9 +111,9 @@  discard block
 block discarded – undo
111 111
         $parseUrl = parse_url($url);
112 112
         if ($this->isCorrectUrl($parseUrl)) {
113 113
             return '';
114
-        } elseif(isset($parseUrl['scheme'])) {
114
+        } elseif (isset($parseUrl['scheme'])) {
115 115
             return $parseUrl['scheme'] . '://' . $parseUrl['host'];
116
-        } else {
116
+        }else {
117 117
             return $parseUrl['host'];
118 118
         }
119 119
     }
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
     public function upToLastDir($url) {
124 124
         $parseUrl = parse_url($url);
125 125
         $path = '';
126
-        if(isset($parseUrl['path'])) {
126
+        if (isset($parseUrl['path'])) {
127 127
                     $path = preg_replace('/\/([^\/]+)$/i', '', $parseUrl['path']);
128 128
         }
129 129
         return rtrim($parseUrl['scheme'] . '://' . $parseUrl['host'] . $path, '/') . '/';
@@ -162,12 +162,12 @@  discard block
 block discarded – undo
162 162
      */
163 163
     public function getStarterPath(): string
164 164
     {
165
-        if ($this->starterPath===null) {
165
+        if ($this->starterPath === null) {
166 166
             if ($this->getBaseTag() === null) {
167
-                $this->starterPath =$this->getPagePath();
167
+                $this->starterPath = $this->getPagePath();
168 168
             } elseif (array_key_exists('scheme', $this->getBaseTagParsing())) {
169
-                $this->starterPath = $this->getBaseTag() ;
170
-            } else {
169
+                $this->starterPath = $this->getBaseTag();
170
+            }else {
171 171
                 $this->starterPath = $this->getPagePathParsing()['scheme'] . '://' . $this->getPagePathParsing()['host'] . $this->getBaseTag();
172 172
             }
173 173
         }
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
         if ($this->domain === null) {
180 180
             if ($this->getBaseTag() === null) {
181 181
                 $this->domain = $this->getPagePathParsing()['host'] . '/';
182
-            }elseif (array_key_exists('scheme', $this->getBaseTagParsing())){
182
+            }elseif (array_key_exists('scheme', $this->getBaseTagParsing())) {
183 183
                 $this->domain = $this->getBaseTagParsing()['host'] . '/';
184 184
             }else {
185 185
                 $this->domain = $this->getPagePathParsing()['host'] . '/';
@@ -193,7 +193,7 @@  discard block
 block discarded – undo
193 193
         if ($this->scheme === null) {
194 194
             if ($this->getBaseTag() === null) {
195 195
                 $this->scheme = $this->getPagePathParsing()['scheme'];
196
-            }elseif (array_key_exists('scheme', $this->getBaseTagParsing())){
196
+            }elseif (array_key_exists('scheme', $this->getBaseTagParsing())) {
197 197
                 $this->scheme = $this->getBaseTagParsing()['scheme'];
198 198
             }else {
199 199
                 $this->scheme = $this->getPagePathParsing()['scheme'];
@@ -207,7 +207,7 @@  discard block
 block discarded – undo
207 207
         if ($this->baseTagParsing == null) {
208 208
             if (is_string($this->getBaseTag())) {
209 209
                 $this->baseTagParsing = parse_url($this->getBaseTag());
210
-            } else {
210
+            }else {
211 211
                 $this->baseTagParsing = [];
212 212
             }
213 213
         }
Please login to merge, or discard this patch.
Braces   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -179,9 +179,9 @@  discard block
 block discarded – undo
179 179
         if ($this->domain === null) {
180 180
             if ($this->getBaseTag() === null) {
181 181
                 $this->domain = $this->getPagePathParsing()['host'] . '/';
182
-            }elseif (array_key_exists('scheme', $this->getBaseTagParsing())){
182
+            } elseif (array_key_exists('scheme', $this->getBaseTagParsing())){
183 183
                 $this->domain = $this->getBaseTagParsing()['host'] . '/';
184
-            }else {
184
+            } else {
185 185
                 $this->domain = $this->getPagePathParsing()['host'] . '/';
186 186
             }
187 187
         }
@@ -193,9 +193,9 @@  discard block
 block discarded – undo
193 193
         if ($this->scheme === null) {
194 194
             if ($this->getBaseTag() === null) {
195 195
                 $this->scheme = $this->getPagePathParsing()['scheme'];
196
-            }elseif (array_key_exists('scheme', $this->getBaseTagParsing())){
196
+            } elseif (array_key_exists('scheme', $this->getBaseTagParsing())){
197 197
                 $this->scheme = $this->getBaseTagParsing()['scheme'];
198
-            }else {
198
+            } else {
199 199
                 $this->scheme = $this->getPagePathParsing()['scheme'];
200 200
             }
201 201
         }
Please login to merge, or discard this patch.