From 9ba51985d7c42e9d7033287749c6e2eb056e9576 Mon Sep 17 00:00:00 2001 From: JT Smith Date: Sat, 2 Nov 2002 19:49:42 +0000 Subject: [PATCH] Fixed a duplication bug. --- lib/WebGUI/Wobject/FAQ.pm | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/lib/WebGUI/Wobject/FAQ.pm b/lib/WebGUI/Wobject/FAQ.pm index fd0eb09be..43a150f8e 100644 --- a/lib/WebGUI/Wobject/FAQ.pm +++ b/lib/WebGUI/Wobject/FAQ.pm @@ -33,9 +33,7 @@ sub duplicate { $w = $_[0]->SUPER::duplicate($_[1]); $w = WebGUI::Wobject::FAQ->new({wobjectId=>$w,namespace=>$namespace}); $w->set({ - topOn=>$_[0]->get("topOn"), - tocOn=>$_[0]->get("tocOn"), - qaOn=>$_[0]->get("qaOn") + templateId=>$_[0]->get("templateId") }); $sth = WebGUI::SQL->read("select * from FAQ_question where wobjectId=".$_[0]->get("wobjectId")); while (%data = $sth->hash) { @@ -179,9 +177,8 @@ sub www_moveQuestionUp { #------------------------------------------------------------------- sub www_view { - my (%question, $output, $controls, $sth, %var, @qa, @toc); + my (%question, $controls, $sth, %var, @qa, @toc); tie %question,'Tie::CPHash'; - $output = $_[0]->displayTitle; if ($session{var}{adminOn}) { $var{addquestion} .= '' .WebGUI::International::get(9,$namespace).''; @@ -209,7 +206,7 @@ sub www_view { $sth->finish; $var{toc_loop} = \@toc; $var{qa_loop} = \@qa; - return $_[0]->processMacros($output.$_[0]->processTemplate($_[0]->get("templateId"),\%var)); + return $_[0]->processMacros($_[0]->displayTitle.$_[0]->processTemplate($_[0]->get("templateId"),\%var)); }