diff options
author | Meik Sievertsen <acydburn@phpbb.com> | 2006-11-12 15:35:43 +0000 |
---|---|---|
committer | Meik Sievertsen <acydburn@phpbb.com> | 2006-11-12 15:35:43 +0000 |
commit | d89f60f182afa07e28d4e58f59b90dd25555e3a6 (patch) | |
tree | b326dbe53f284a7127ea8a63cccc7119dc77783d /phpBB/includes/cache.php | |
parent | b0217ddc11799f81c8cf42961f6e0db54ce2e38e (diff) | |
download | forums-d89f60f182afa07e28d4e58f59b90dd25555e3a6.tar forums-d89f60f182afa07e28d4e58f59b90dd25555e3a6.tar.gz forums-d89f60f182afa07e28d4e58f59b90dd25555e3a6.tar.bz2 forums-d89f60f182afa07e28d4e58f59b90dd25555e3a6.tar.xz forums-d89f60f182afa07e28d4e58f59b90dd25555e3a6.zip |
consistant obtain_* functions
git-svn-id: file:///svn/phpbb/trunk@6572 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/cache.php')
-rw-r--r-- | phpBB/includes/cache.php | 33 |
1 files changed, 18 insertions, 15 deletions
diff --git a/phpBB/includes/cache.php b/phpBB/includes/cache.php index 01dcf5b722..6266d32c0f 100644 --- a/phpBB/includes/cache.php +++ b/phpBB/includes/cache.php @@ -70,13 +70,13 @@ class cache extends acm * Obtain list of naughty words and build preg style replacement arrays for use by the * calling script */ - function obtain_word_list(&$censors) + function obtain_word_list() { global $config, $user, $db; if (!$user->optionget('viewcensors') && $config['allow_nocensors']) { - return false; + return array(); } if (($censors = $this->get('word_censors')) === false) @@ -96,13 +96,13 @@ class cache extends acm $this->put('word_censors', $censors); } - return true; + return $censors; } /** * Obtain currently listed icons */ - function obtain_icons(&$icons) + function obtain_icons() { if (($icons = $this->get('icons')) === false) { @@ -127,13 +127,13 @@ class cache extends acm $this->put('icons', $icons); } - return; + return $icons; } /** * Obtain ranks */ - function obtain_ranks(&$ranks) + function obtain_ranks() { if (($ranks = $this->get('ranks')) === false) { @@ -168,13 +168,13 @@ class cache extends acm $this->put('ranks', $ranks); } - return; + return $ranks; } /** * Obtain allowed extensions */ - function obtain_attach_extensions(&$extensions, $forum_id = false) + function obtain_attach_extensions($forum_id = false) { if (($extensions = $this->get('_extensions')) === false) { @@ -254,13 +254,13 @@ class cache extends acm $extensions['_allowed_'] = array(); } - return; + return $extensions; } /** * Obtain active bots */ - function obtain_bots(&$bots) + function obtain_bots() { if (($bots = $this->get('bots')) === false) { @@ -303,7 +303,7 @@ class cache extends acm $this->put('bots', $bots); } - return; + return $bots; } /** @@ -355,9 +355,12 @@ class cache extends acm return $parsed_items; } - function obtain_disallowed_usernames(&$usernames) + /** + * Obtain disallowed usernames + */ + function obtain_disallowed_usernames() { - if (($usernames = $this->get('disallowed_usernames')) === false) + if (($usernames = $this->get('_disallowed_usernames')) === false) { global $db; @@ -372,10 +375,10 @@ class cache extends acm } $db->sql_freeresult($result); - $this->put('disallowed_usernames', $usernames); + $this->put('_disallowed_usernames', $usernames); } - return true; + return $usernames; } } |