From 409139fabdde2dd16ef443920e670e3192581623 Mon Sep 17 00:00:00 2001 From: Melnikov Alexandr Date: Fri, 20 Oct 2017 11:21:18 +0600 Subject: [PATCH 1/3] Added context to App facade constructor --- src/Ratchet/App.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Ratchet/App.php b/src/Ratchet/App.php index f1cd4dd..d3de200 100644 --- a/src/Ratchet/App.php +++ b/src/Ratchet/App.php @@ -61,8 +61,9 @@ class App { * @param int $port Port to listen on. If 80, assuming production, Flash on 843 otherwise expecting Flash to be proxied through 8843 * @param string $address IP address to bind to. Default is localhost/proxy only. '0.0.0.0' for any machine. * @param LoopInterface $loop Specific React\EventLoop to bind the application to. null will create one for you. + * @param array $context */ - public function __construct($httpHost = 'localhost', $port = 8080, $address = '127.0.0.1', LoopInterface $loop = null) { + public function __construct($httpHost = 'localhost', $port = 8080, $address = '127.0.0.1', LoopInterface $loop = null, $context = array()) { if (extension_loaded('xdebug') && getenv('RATCHET_DISABLE_XDEBUG_WARN') === false) { trigger_error('XDebug extension detected. Remember to disable this if performance testing or going live!', E_USER_WARNING); } @@ -74,7 +75,7 @@ class App { $this->httpHost = $httpHost; $this->port = $port; - $socket = new Reactor($address . ':' . $port, $loop); + $socket = new Reactor($address . ':' . $port, $loop, $context); $this->routes = new RouteCollection; $this->_server = new IoServer(new HttpServer(new Router(new UrlMatcher($this->routes, new RequestContext))), $socket, $loop); From 3e97459d3f591d6439ff7cae016e749335b9a047 Mon Sep 17 00:00:00 2001 From: Minifets Date: Fri, 20 Oct 2017 11:34:51 +0600 Subject: [PATCH 2/3] Update composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index acf4722..fce17ca 100644 --- a/composer.json +++ b/composer.json @@ -1,5 +1,5 @@ { - "name": "cboden/ratchet" + "name": "minifets/ratchet" , "type": "library" , "description": "PHP WebSocket library" , "keywords": ["WebSockets", "Server", "Ratchet", "Sockets", "WebSocket"] From 5b0194167eac46aec79c6b8ad814c482b93a38fe Mon Sep 17 00:00:00 2001 From: "minifets@DESKTOP-QP6P5N5.localdomain" Date: Fri, 20 Oct 2017 20:40:47 +0600 Subject: [PATCH 3/3] Revert "Update composer.json" This reverts commit 5ebe073fee0f04a7d26aaa0504b0e8b69d0d2e36. --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index fce17ca..acf4722 100644 --- a/composer.json +++ b/composer.json @@ -1,5 +1,5 @@ { - "name": "minifets/ratchet" + "name": "cboden/ratchet" , "type": "library" , "description": "PHP WebSocket library" , "keywords": ["WebSockets", "Server", "Ratchet", "Sockets", "WebSocket"]