From 4b7f9e7005c4562f8b4b554ea5ea53fb1ebf804a Mon Sep 17 00:00:00 2001 From: Tom N Harris Date: Thu, 28 May 2009 23:54:38 +0200 Subject: Change expensive uses of split to the much faster explode. darcs-hash:20090528215438-6942e-bf1b875e689ade6bd1a17e3d812ce16bf35c84a6.gz --- inc/auth/plain.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'inc/auth') diff --git a/inc/auth/plain.class.php b/inc/auth/plain.class.php index 02175d962..68976287a 100644 --- a/inc/auth/plain.class.php +++ b/inc/auth/plain.class.php @@ -278,8 +278,8 @@ class auth_plain extends auth_basic { $line = trim($line); if(empty($line)) continue; - $row = split(":",$line,5); - $groups = split(",",$row[4]); + $row = explode(":",$line,5); + $groups = array_values(array_filter(explode(",",$row[4]))); $this->users[$row[0]]['pass'] = $row[1]; $this->users[$row[0]]['name'] = urldecode($row[2]); -- cgit v1.2.3