Passed
Push — master ( 96a53b...3e41c0 )
by Filippo
01:44
created
src/Surfer/Adapter/AbstractAdapter.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@
 block discarded – undo
76 76
     if (preg_match(self::SCHEME_HOST_PORT_URI, $server, $matches)) {
77 77
       $this->scheme = isset($matches['scheme']) ? $matches['scheme'] : "tcp://";
78 78
       $this->host = isset($matches['host']) ? $matches['host'] : self::DEFAULT_HOST;
79
-      $this->port = isset($matches['port']) ? (int) substr($matches['port'], 1) : self::$defaultPorts[$this->scheme];
79
+      $this->port = isset($matches['port']) ? (int)substr($matches['port'], 1) : self::$defaultPorts[$this->scheme];
80 80
     }
81 81
     else // Match attempt failed.
82 82
       throw new \InvalidArgumentException(sprintf("'%s' is not a valid URI.", $server));
Please login to merge, or discard this patch.
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -77,9 +77,10 @@
 block discarded – undo
77 77
       $this->scheme = isset($matches['scheme']) ? $matches['scheme'] : "tcp://";
78 78
       $this->host = isset($matches['host']) ? $matches['host'] : self::DEFAULT_HOST;
79 79
       $this->port = isset($matches['port']) ? (int) substr($matches['port'], 1) : self::$defaultPorts[$this->scheme];
80
-    }
81
-    else // Match attempt failed.
80
+    } else {
81
+      // Match attempt failed.
82 82
       throw new \InvalidArgumentException(sprintf("'%s' is not a valid URI.", $server));
83
+    }
83 84
 
84 85
     $this->userName = (string)$userName;
85 86
     $this->password = (string)$password;
Please login to merge, or discard this patch.