[Jifty-commit] r1031 - in jifty/trunk: lib lib/Jifty lib/Jifty/Web
jifty-commit at lists.jifty.org
jifty-commit at lists.jifty.org
Wed May 10 16:09:36 EDT 2006
Author: alexmv
Date: Wed May 10 16:09:32 2006
New Revision: 1031
Modified:
jifty/trunk/ (props changed)
jifty/trunk/lib/Jifty.pm
jifty/trunk/lib/Jifty/Dispatcher.pm
jifty/trunk/lib/Jifty/Util.pm
jifty/trunk/lib/Jifty/Web/PageRegion.pm
Log:
r12949 at zoq-fot-pik: chmrr | 2006-05-10 16:08:45 -0400
* Dispatcher fixes -- Jifty->dispatcher was a Jifty::Dispatcher,
which never had any rules on it, so dispatching from it never did
anything. Remove Jifty->dispatcher in favor of
Jifty->handler->dispatcher, which does work. This means that
fragments *actually* go through the siaptcher now.
* The main dispatcher array is RULES_RUN not RULES.
Modified: jifty/trunk/lib/Jifty.pm
==============================================================================
--- jifty/trunk/lib/Jifty.pm (original)
+++ jifty/trunk/lib/Jifty.pm Wed May 10 16:09:32 2006
@@ -62,7 +62,7 @@
use base qw/Jifty::Object/;
use Jifty::Everything;
-use vars qw/$HANDLE $CONFIG $LOGGER $HANDLER $DISPATCHER $API/;
+use vars qw/$HANDLE $CONFIG $LOGGER $HANDLER $API/;
=head1 METHODS
@@ -116,10 +116,9 @@
push @Jifty::Record::ISA, Jifty->config->framework('Database')->{'RecordBaseClass'};
__PACKAGE__->logger( Jifty::Logger->new( $args{'logger_component'} ) );
- # Get a classloader set up
- Jifty::ClassLoader->new->require;
+ # Get a classloader set up
+ Jifty::ClassLoader->new->require;
- __PACKAGE__->dispatcher(Jifty::Dispatcher->new());
__PACKAGE__->handler(Jifty::Handler->new());
__PACKAGE__->api(Jifty::API->new());
@@ -181,19 +180,6 @@
return $HANDLE;
}
-=head2 dispatcher
-
-An accessor for the C<Jifty::Dispatcher> object that we use to make
-decisions about how to dispatch each request made by a web client.
-
-=cut
-
-sub dispatcher {
- my $class = shift;
- $DISPATCHER = shift if (@_);
- return $DISPATCHER;
-}
-
=head2 api
An accessor for the L<Jifty::API> object that publishes and controls
Modified: jifty/trunk/lib/Jifty/Dispatcher.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Dispatcher.pm (original)
+++ jifty/trunk/lib/Jifty/Dispatcher.pm Wed May 10 16:09:32 2006
@@ -284,7 +284,7 @@
no strict 'refs';
no warnings 'once';
- for (qw(RULES RULES_SETUP RULES_CLEANUP)) {
+ for (qw(RULES_RUN RULES_SETUP RULES_CLEANUP)) {
@{ $pkg . '::' . $_ } = ();
}
if ( @args != @_ ) {
Modified: jifty/trunk/lib/Jifty/Util.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Util.pm (original)
+++ jifty/trunk/lib/Jifty/Util.pm Wed May 10 16:09:32 2006
@@ -180,7 +180,7 @@
my $retval = $class->require;
if ($UNIVERSAL::require::ERROR) {
- my $error = $UNIVERSAL::require::ERROR;
+ my $error = $UNIVERSAL::require::ERROR;
$error =~ s/ at .*?\n$//;
Jifty->log->error(sprintf("$error at %s line %d\n", (caller)[1,2]));
return 0;
Modified: jifty/trunk/lib/Jifty/Web/PageRegion.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Web/PageRegion.pm (original)
+++ jifty/trunk/lib/Jifty/Web/PageRegion.pm Wed May 10 16:09:32 2006
@@ -294,7 +294,7 @@
Jifty->handler->mason->interp->out_method( \$region_content );
# Call into the dispatcher
- Jifty->dispatcher->handle_request;
+ Jifty->handler->dispatcher->handle_request;
$result .= $region_content;
$result .= qq|</div>| if ( $self->region_wrapper );
More information about the Jifty-commit
mailing list