aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Server.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/Server.php b/Server.php
index 6afe34f..86f1227 100644
--- a/Server.php
+++ b/Server.php
@@ -90,7 +90,9 @@ class Server extends Connection
{
$connection = $this->getConnection();
- if (true === $connection->getSocket()->isSecured()) {
+ if (true === $connection->getSocket()->isSecured()
+ && false === $connection->isEncrypted()
+ ) {
$connection->enableEncryption(true, $connection::ENCRYPTION_TLS);
}