[Jifty-commit] r646 -
jifty-commit at lists.jifty.org
jifty-commit at lists.jifty.org
Fri Mar 3 19:02:26 EST 2006
Author: jesse
Date: Fri Mar 3 19:02:26 2006
New Revision: 646
Modified:
/ (props changed)
jifty/trunk/lib/Jifty/Handler.pm
Log:
r25143 at truegrounds: jesse | 2006-03-03 09:21:42 -0800
* Only init mason once, not once per request. We used to need to do this
because of a bug in page regions
Modified: jifty/trunk/lib/Jifty/Handler.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Handler.pm (original)
+++ jifty/trunk/lib/Jifty/Handler.pm Fri Mar 3 19:02:26 2006
@@ -36,10 +36,11 @@
sub new {
my $class = shift;
- my $self = {};
+ my $self = {};
bless $self, $class;
$self->create_cache_directories();
+
# Creating a new CGI object breaks FastCGI in all sorts of painful
# ways. So wrap the call and preempt it if we already have one
use CGI;
@@ -47,9 +48,10 @@
$_[-1] = Jifty->handler->cgi if Jifty->handler->cgi;
};
-
- $self->dispatcher(Jifty->config->framework('ApplicationClass')."::Dispatcher");
- Jifty::Util->require($self->dispatcher);
+ $self->dispatcher(
+ Jifty->config->framework('ApplicationClass') . "::Dispatcher" );
+ Jifty::Util->require( $self->dispatcher );
+ $self->mason( Jifty::MasonHandler->new( $self->mason_config ) );
return $self;
}
@@ -156,7 +158,6 @@
# This should done in "new", but something is causing Jifty to handle
# one and only one session. after that, it gives us http headers but no content
#
- $self->mason(Jifty::MasonHandler->new( $self->mason_config,));
$self->dispatcher->handle_request();
$self->cleanup_request();
More information about the Jifty-commit
mailing list