From ab6fdfa8bc3a441590778b026b52225473424eec Mon Sep 17 00:00:00 2001
From: Aleksander Machniak <alec@alec.pl>
Date: Fri, 20 May 2016 08:08:28 -0400
Subject: [PATCH] Fix PHP warning when password_hosts is set, but is not an array (#5260)

---
 plugins/password/password.php |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/plugins/password/password.php b/plugins/password/password.php
index f84dc8f..520f250 100644
--- a/plugins/password/password.php
+++ b/plugins/password/password.php
@@ -369,7 +369,7 @@
 
         // Host exceptions
         $hosts = $rcmail->config->get('password_hosts');
-        if (!empty($hosts) && !in_array($_SESSION['storage_host'], $hosts)) {
+        if (!empty($hosts) && !in_array($_SESSION['storage_host'], (array) $hosts)) {
             return false;
         }
 

--
Gitblit v1.9.1