From f3ba69c1d67c425ffa180d082a373e5cce0c86ce Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Wed, 14 Jan 2009 04:12:02 +0000 Subject: Make sure that helper functions are all static. Add new File_Structure_Test to make sure we don't regress. According to the PHP docs, the "public" keyword is implied on static functions, so remove it. Also, require private static functions to start with an _. http://php.net/manual/en/language.oop5.visibility.php --- core/helpers/core_block.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'core/helpers/core_block.php') diff --git a/core/helpers/core_block.php b/core/helpers/core_block.php index e005b67d..35bba06f 100644 --- a/core/helpers/core_block.php +++ b/core/helpers/core_block.php @@ -19,7 +19,7 @@ */ class core_block_Core { - public static function head($theme) { + static function head($theme) { $buf = ""; if (Session::instance()->get("debug")) { $buf .= "type == "photo" && access::can("edit", $child)) { $edit_link = url::site("quick/pane/$child->id"); return "
"; } } - public static function thumb_bottom($theme, $child) { + static function thumb_bottom($theme, $child) { if ($child->type == "photo" && access::can("edit", $child)) { return "
"; } } - public static function admin_head($theme) { + static function admin_head($theme) { if (Session::instance()->get("debug")) { return ""; } } - public static function page_bottom($theme) { + static function page_bottom($theme) { if (Session::instance()->get("profiler", false)) { $profiler = new Profiler(); $profiler->render(); } } - public static function admin_page_bottom($theme) { + static function admin_page_bottom($theme) { if (Session::instance()->get("profiler", false)) { $profiler = new Profiler(); $profiler->render(); -- cgit v1.2.3