From ba80566b1eae376997567c2801c65e8e358612ed Mon Sep 17 00:00:00 2001 From: alecpl <alec@alec.pl> Date: Mon, 20 Oct 2008 05:21:36 -0400 Subject: [PATCH] - little improvement in in_array_nocase() --- program/include/rcube_shared.inc | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/program/include/rcube_shared.inc b/program/include/rcube_shared.inc index af5eb1f..3b63d9c 100644 --- a/program/include/rcube_shared.inc +++ b/program/include/rcube_shared.inc @@ -209,8 +209,9 @@ */ function in_array_nocase($needle, $haystack) { + $needle = rc_strtolower($needle); foreach ($haystack as $value) - if (rc_strtolower($needle)===rc_strtolower($value)) + if ($needle===rc_strtolower($value)) return true; return false; -- Gitblit v1.9.1