From dc414e13e56cede4129de6c0035fd18c550b43a7 Mon Sep 17 00:00:00 2001 From: Matthew Wilson Date: Mon, 17 Apr 2006 01:32:31 +0000 Subject: [PATCH] fixed form process bug. $session->form->TYPE should only retrieve by name. --- lib/WebGUI/Session/Form.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/WebGUI/Session/Form.pm b/lib/WebGUI/Session/Form.pm index 594fc77aa..e72e9ec9f 100644 --- a/lib/WebGUI/Session/Form.pm +++ b/lib/WebGUI/Session/Form.pm @@ -58,7 +58,7 @@ sub AUTOLOAD { our $AUTOLOAD; my $self = shift; my $name = ucfirst((split /::/, $AUTOLOAD)[-1]); - my $params = shift; + my $varName = shift; my $cmd = "use WebGUI::Form::".$name; eval ($cmd); if ($@) { @@ -66,7 +66,7 @@ sub AUTOLOAD { return undef; } my $class = "WebGUI::Form::".$name; - return $class->new($self->session, $params)->getValueFromPost; + return $class->new($self->session, {name=>$varName})->getValueFromPost; } #-------------------------------------------------------------------