Blob Blame History Raw
From 64f88d3598ffd833506b450f72f0aa5ef8a55f3c Mon Sep 17 00:00:00 2001
From: Remi Collet <fedora@famillecollet.com>
Date: Tue, 10 Nov 2015 07:31:38 +0100
Subject: [PATCH] fix warning

---
 Sieve.php | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/Sieve.php b/Sieve.php
index 9f9bf71..6509123 100644
--- a/Sieve.php
+++ b/Sieve.php
@@ -309,7 +309,11 @@ function connect($host, $port, $options = null, $useTLS = true)
         $this->_data['port'] = $port;
         $this->_useTLS       = $useTLS;
         if (is_array($options)) {
-            $this->_options = array_merge($this->_options, $options);
+            if (is_array($this->_options)) {
+                $this->_options = array_merge($this->_options, $options);
+            } else {
+                $this->_options = $options;
+            }
         }
 
         if (NET_SIEVE_STATE_DISCONNECTED != $this->_state) {