From 257c920839164e2e3c8381a934fb82ff72e7c2f5 Mon Sep 17 00:00:00 2001 From: Quentin Bellus Date: Thu, 2 Apr 2015 20:02:48 +0100 Subject: [PATCH] Fixing full address in error $path_with_query already contains a leading / --- lib/Client.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Client.php b/lib/Client.php index 82982a0..8461240 100644 --- a/lib/Client.php +++ b/lib/Client.php @@ -115,7 +115,7 @@ function($key, $value) { return "$key: $value"; }, array_keys($headers), $header // Validate response. if (!preg_match('#Sec-WebSocket-Accept:\s(.*)$#mUi', $response, $matches)) { - $address = $scheme . '://' . $host . '/' . $path_with_query; + $address = $scheme . '://' . $host . $path_with_query; throw new ConnectionException( "Connection to '{$address}' failed: Server sent invalid upgrade response:\n" . $response