@@ -91,7 +91,7 @@ discard block |
||
| 91 | 91 | |
| 92 | 92 | if ($url['url'] instanceof UriInterface) { |
| 93 | 93 | $urlObject = $url['url']; |
| 94 | - }else { |
|
| 94 | + } else { |
|
| 95 | 95 | $urlObject = new Uri($url['url']); |
| 96 | 96 | } |
| 97 | 97 | |
@@ -112,20 +112,20 @@ discard block |
||
| 112 | 112 | /* @var \Ivory\HttpAdapter\HttpAdapterException $exception */ |
| 113 | 113 | |
| 114 | 114 | $mainUri = $request->getUri(); |
| 115 | - $this->redirects[(string)$mainUri->getScheme() . '://' . $mainUri->getHost() . $corruptUrl] = (string)$mainUri; |
|
| 115 | + $this->redirects[(string) $mainUri->getScheme().'://'.$mainUri->getHost().$corruptUrl] = (string) $mainUri; |
|
| 116 | 116 | |
| 117 | - $this->urls[] = ['url' => $mainUri->getScheme() . '://' . $mainUri->getHost() . $corruptUrl, 'system' => $url['system']]; |
|
| 118 | - $this->urlStack[] = ['url' => $mainUri->getScheme() . '://' . $mainUri->getHost() . $corruptUrl, 'system' => $url['system']]; |
|
| 117 | + $this->urls[] = ['url' => $mainUri->getScheme().'://'.$mainUri->getHost().$corruptUrl, 'system' => $url['system']]; |
|
| 118 | + $this->urlStack[] = ['url' => $mainUri->getScheme().'://'.$mainUri->getHost().$corruptUrl, 'system' => $url['system']]; |
|
| 119 | 119 | |
| 120 | 120 | return $this->next(); |
| 121 | 121 | } |
| 122 | 122 | |
| 123 | 123 | // the error handling should be done withing the calling class |
| 124 | - echo "\n " . $exception->getMessage() . "\n"; |
|
| 124 | + echo "\n ".$exception->getMessage()."\n"; |
|
| 125 | 125 | |
| 126 | 126 | return $this->next(); |
| 127 | 127 | } else { |
| 128 | - $errorMessages .= $exception->getMessage() . "\n"; |
|
| 128 | + $errorMessages .= $exception->getMessage()."\n"; |
|
| 129 | 129 | } |
| 130 | 130 | } |
| 131 | 131 | if ($errorMessages !== '') { |
@@ -138,8 +138,8 @@ discard block |
||
| 138 | 138 | |
| 139 | 139 | public function getOriginUri(UriInterface $uri) |
| 140 | 140 | { |
| 141 | - if (array_key_exists((string)$uri, $this->redirects)) { |
|
| 142 | - return $this->urls[$this->redirects[(string)$uri]]['url']; |
|
| 141 | + if (array_key_exists((string) $uri, $this->redirects)) { |
|
| 142 | + return $this->urls[$this->redirects[(string) $uri]]['url']; |
|
| 143 | 143 | } |
| 144 | 144 | |
| 145 | 145 | return $uri; |
@@ -152,11 +152,11 @@ discard block |
||
| 152 | 152 | |
| 153 | 153 | public function getSystem(UriInterface $uri) |
| 154 | 154 | { |
| 155 | - if (array_key_exists((string)$uri, $this->redirects)) { |
|
| 156 | - return $this->urls[$this->redirects[(string)$uri]]['system']; |
|
| 155 | + if (array_key_exists((string) $uri, $this->redirects)) { |
|
| 156 | + return $this->urls[$this->redirects[(string) $uri]]['system']; |
|
| 157 | 157 | } |
| 158 | 158 | |
| 159 | - return $this->urls[(string)$uri]['system']; |
|
| 159 | + return $this->urls[(string) $uri]['system']; |
|
| 160 | 160 | } |
| 161 | 161 | |
| 162 | 162 | public function getSystems() |
@@ -91,7 +91,7 @@ |
||
| 91 | 91 | |
| 92 | 92 | if ($url['url'] instanceof UriInterface) { |
| 93 | 93 | $urlObject = $url['url']; |
| 94 | - }else { |
|
| 94 | + } else { |
|
| 95 | 95 | $urlObject = new Uri($url['url']); |
| 96 | 96 | } |
| 97 | 97 | |
@@ -20,7 +20,7 @@ |
||
| 20 | 20 | $this->sessionContainer = new SessionContainer(); |
| 21 | 21 | |
| 22 | 22 | foreach ($sessions as $sessionName => $session) { |
| 23 | - $command = $this->executable . " '" . json_encode($session) . "' '" . $cacheDir . "' '" . $webdriverHost . "'"; |
|
| 23 | + $command = $this->executable." '".json_encode($session)."' '".$cacheDir."' '".$webdriverHost."'"; |
|
| 24 | 24 | |
| 25 | 25 | exec($command, $output, $return); |
| 26 | 26 | |