From 4095a7ed6ef5203437f0d05cccf2f3f00efd4693 Mon Sep 17 00:00:00 2001 From: Chris Boden Date: Mon, 8 Feb 2016 07:51:54 -0500 Subject: [PATCH] Change scope, defensive --- src/Handshake/ClientNegotiator.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/Handshake/ClientNegotiator.php b/src/Handshake/ClientNegotiator.php index ca93669..8726c8f 100644 --- a/src/Handshake/ClientNegotiator.php +++ b/src/Handshake/ClientNegotiator.php @@ -14,7 +14,7 @@ class ClientNegotiator { /** * @var \Psr\Http\Message\RequestInterface */ - public $defaultHeader; + private $defaultHeader; function __construct() { $this->verifier = new ResponseVerifier; @@ -29,7 +29,6 @@ class ClientNegotiator { public function generateRequest(UriInterface $uri) { return $this->defaultHeader->withUri($uri) - ->withoutHeader("Sec-WebSocket-Key") ->withHeader("Sec-WebSocket-Key", $this->generateKey()); }