From 28ef43fdf4c7bc3be6b2927836bfc623dcc42070 Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Fri, 13 Jan 2006 02:17:46 +0000 Subject: [PATCH] No longer need to create a temporary template object due to init_as_package() --- kernel.php | 22 ++++------------------ 1 file changed, 4 insertions(+), 18 deletions(-) diff --git a/kernel.php b/kernel.php index 61ba42c..e8834dc 100644 --- a/kernel.php +++ b/kernel.php @@ -1077,32 +1077,18 @@ class Shared_Object_Framework // templates if ($dotemplates) { - // both template and template_fs are viable, so we need to determine the right one - if ($this->is_loaded('template')) - { - $tpl_obj =& $this->modules['template']; - } - else if ($this->is_loaded('template_fs')) - { - $tpl_obj =& $this->modules['template_fs']; - } - else - { - $tpl_obj = null; - } - $optlist = array(); $usage = array(); - foreach ($tpl_obj->usage AS $name => $count) + foreach ($this->modules['template']->usage AS $name => $count) { - if (in_array($name, $tpl_obj->uncached)) + if (in_array($name, $this->modules['template']->uncached)) { $optlist[] = $name . '[' . $count . ']'; } $usage[] = $name . " ($count)"; } - $sizeof = sizeof($tpl_obj->uncached); + $sizeof = sizeof($this->modules['template']->uncached); if ($sizeof > 0) { $debug .= "\n\t
  • Uncached Template(s): $sizeof ( " . implode('   ', $optlist) . " )
  • "; @@ -1163,7 +1149,7 @@ class Shared_Object_Framework // template usage if ($dotemplates) { - $debug .= "\n\t
  • \n\t\t\n\t\t\t"; foreach ($usage AS $tpl) { $debug .= "\n\t\t\t"; -- 2.43.5