smarty) ? $obj->smarty : $obj; if (!isset($smarty->registered_objects[$object_name])) { throw new SmartyException("'$object_name' is not a registered object"); } if (!is_object($smarty->registered_objects[$object_name][0])) { throw new SmartyException("registered '$object_name' is not an object"); } return $smarty->registered_objects[$object_name][0]; } }