[Catalyst-commits] r8030 - trunk/CatalystX-Imports/lib/CatalystX/Imports

rafl at dev.catalyst.perl.org rafl at dev.catalyst.perl.org
Sat Jun 28 15:15:34 BST 2008


Author: rafl
Date: 2008-06-28 15:15:34 +0100 (Sat, 28 Jun 2008)
New Revision: 8030

Modified:
   trunk/CatalystX-Imports/lib/CatalystX/Imports/Vars.pm
Log:
Implement flash vars.

Modified: trunk/CatalystX-Imports/lib/CatalystX/Imports/Vars.pm
===================================================================
--- trunk/CatalystX-Imports/lib/CatalystX/Imports/Vars.pm	2008-06-28 14:15:26 UTC (rev 8029)
+++ trunk/CatalystX-Imports/lib/CatalystX/Imports/Vars.pm	2008-06-28 14:15:34 UTC (rev 8030)
@@ -87,6 +87,7 @@
     # fetch session and
     my @session = @{ $args->{Session} || [] };
     my @stash   = @{ $args->{Stash}   || [] };
+    my @flash   = @{ $args->{Flash}   || [] };
 
     # build map of symbol hash refs, containing method, type and
     # sym (name)
@@ -94,11 +95,11 @@
         map { {method => $_->[0], type => $_->[2], sym => $_->[3]} }
         map { [@$_, $class->_destruct_var_name($_->[1])] }
         map { my $x = $_; map { [$x->[0], $_] } @{ $x->[1] } }
-            [session => \@session], [stash => \@stash];
+            [session => \@session], [stash => \@stash], [flash => \@flash];
 
     # export all symbols into the requesting namespace, include defaults
     $class->export_var_into($target, $class->_destruct_var_name($_))
-        for @session, @stash, qw($self $ctx @args);
+        for @session, @stash, @flash, qw($self $ctx @args);
 
     # build and register our action wrapper
     $class->register_action_wrap_in($target, sub {




More information about the Catalyst-commits mailing list