X-Git-Url: https://git.decadent.org.uk/gitweb/?p=maypole.git;a=blobdiff_plain;f=lib%2FApache%2FMVC.pm;h=3ea2d28479dc28d49430c893ba6b7fc18765b3ae;hp=dea64fffa161648d0cf4abb0c19b523c461e78f6;hb=373c588aa7b5a4f0d99a5940fade8a767c6d9426;hpb=88403615773aa8c4a86006b5d41577e586d1c0ec diff --git a/lib/Apache/MVC.pm b/lib/Apache/MVC.pm index dea64ff..3ea2d28 100644 --- a/lib/Apache/MVC.pm +++ b/lib/Apache/MVC.pm @@ -1,6 +1,6 @@ package Apache::MVC; -our $VERSION = '2.11'; +our $VERSION = '2.121'; use strict; use warnings; @@ -93,11 +93,17 @@ functionality. See L for these: sub get_request { my ($self, $r) = @_; + my $request_options = $self->config->request_options || {}; my $ar; if ($MODPERL2) { - $ar = eval {require Apache2::Request} ? Apache2::Request->new($r) : $r; - } - else { $ar = Apache::Request->instance($r); } + $ar = eval {require Apache2::Request} ? Apache2::Request->new($r,%{$request_options}) : $r; + } else { + if (keys %$request_options) { + $ar = Apache::Request->new($r,%{$request_options}); + } else { + $ar = Apache::Request->instance($r); + } + } $self->ar($ar); }