Update of /cvsroot/openinteract/OpenInteract/OpenInteract/Template
In directory usw-pr-cvs1:/tmp/cvs-serv4441/Template
Modified Files:
Process.pm
Log Message:
futz with the content passed into handler; throw an error if the
content isn't available via the means listed
Index: Process.pm
===================================================================
RCS file: /cvsroot/openinteract/OpenInteract/OpenInteract/Template/Process.pm,v
retrieving revision 1.15
retrieving revision 1.16
diff -C2 -d -r1.15 -r1.16
*** Process.pm 2001/10/11 13:28:55 1.15
--- Process.pm 2001/10/24 21:54:00 1.16
***************
*** 90,94 ****
my ( $name, $to_process );
if ( $template_source->{text} ) {
! $to_process = \$template_source->{text};
$name = '_anonymous_';
$R->DEBUG && $R->scrib( 1, "Using raw template source for processing" );
--- 90,95 ----
my ( $name, $to_process );
if ( $template_source->{text} ) {
! $to_process = ( ref $template_source->{text} eq 'SCALAR' )
! ? $template_source->{text} : \$template_source->{text};
$name = '_anonymous_';
$R->DEBUG && $R->scrib( 1, "Using raw template source for processing" );
***************
*** 121,124 ****
--- 122,132 ----
}
+ # Uh oh...
+
+ else {
+ $R->scrib( 0, "No template to process! Information given for source:\n",
+ Dumper( $template_source ) );
+ die "No template to process!\n";
+ }
# Grab the template object and the OI plugin, making the OI plugin
# available to every template
|