Re: [Templates] Template::Service::Apache query
[prev]
[thread]
[next]
[Date index for 2004/10/07]
Paul Makepeace wrote:
> Hi,
>
> sub params {
> my ($self, $request, $params) = @_;
> $params ||= { };
>
> my $plist = $self->{ SERVICE_PARAMS };
> my $all = $plist->{ all };
>
> return $params unless keys %$plist;
> $request = Apache::Request->new($request);
> ^
>
> Is this intentional (Andy)? Was ||= in mind, like for $params?
I think he was trying to make sure that the $request was an
Apache::Request object an not just the Apache->request. They are
different. Creating a new Apache::Request off another Apache::Request
shouldn't be a problem.
If it really concerns you then maybe a
$request = Apache::Request->new($request)
if(! request || (ref $request eq 'Apache'));
> I'm currently trying to (ab)use this module via a custom Maypole view
> and we already have the request object.
>
> Paul
>
> PS thank you for having $params as an in/out var! (merging hashes later)--
>
>
>
--
Michael Peters
Developer
Plus Three, LP
_______________________________________________
templates mailing list
templates@xxxxxxxxxxxxxxxx.xxx
http://lists.template-toolkit.org/mailman/listinfo/templates
 |
 |
Re: [Templates] Template::Service::Apache query
Michael 14:40 on 07 Oct 2004
|