From ea73d58913874e6dab2345910cc51879a32a71bf Mon Sep 17 00:00:00 2001 From: Aleksander Machniak Date: Fri, 20 May 2016 14:08:28 +0200 Subject: [PATCH] Fix PHP warning when password_hosts is set, but is not an array (#5260) --- plugins/password/password.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/password/password.php b/plugins/password/password.php index f84dc8f0d..520f2504e 100644 --- a/plugins/password/password.php +++ b/plugins/password/password.php @@ -369,7 +369,7 @@ class password extends rcube_plugin // 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; }