From 1ec268036cebf90792569d78aa5d4a8701bc40e4 Mon Sep 17 00:00:00 2001 From: Huynh Thanh Van Date: Mon, 10 Sep 2018 16:02:11 +0900 Subject: [PATCH 1/3] Update AbstractConnection.php Use inherited variables in anonymous instead of deprecated Timer:: --- src/Connection/AbstractConnection.php | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/Connection/AbstractConnection.php b/src/Connection/AbstractConnection.php index ec9d025..892ea35 100644 --- a/src/Connection/AbstractConnection.php +++ b/src/Connection/AbstractConnection.php @@ -169,15 +169,11 @@ protected function createResource(callable $callback) */ protected function armTimeoutMonitor($timeout, callable $callback) { - $timer = $this->loop->addTimer($timeout, function ($timer) { - list($connection, $callback) = $timer->getData(); - - $connection->disconnect(); - call_user_func($callback, $connection, new ConnectionException($connection, 'Connection timed out')); + $timer = $this->loop->addTimer($timeout, function ($timer) use ($callback) { + $this->disconnect(); + call_user_func($callback, $this, new ConnectionException($this, 'Connection timed out')); }); - $timer->setData([$this, $callback]); - return $timer; } From 148064d9a27021ec74665702e2c6217f9d755e3a Mon Sep 17 00:00:00 2001 From: Huynh Thanh Van Date: Wed, 12 Sep 2018 16:20:57 +0900 Subject: [PATCH 2/3] Update composer.json update event-loop 1.0 --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 9d6eaa3..1ae7361 100644 --- a/composer.json +++ b/composer.json @@ -15,7 +15,7 @@ "require": { "php": ">=5.4.0", "predis/predis": "^1.0", - "react/event-loop": "~0.4", + "react/event-loop": "~1.0", "clue/redis-protocol": "~0.3" }, "require-dev": { From e7f08f1c7e7eef5da1946dfcf2d821b174245937 Mon Sep 17 00:00:00 2001 From: Huynh Thanh Van Date: Wed, 12 Sep 2018 16:32:38 +0900 Subject: [PATCH 3/3] Update VERSION --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index d510910..746bd19 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.3.0-dev +0.3.1-dev