[interchange-cvs] interchange - jon modified lib/Vend/Interpolate.pm

interchange-core@icdevgroup.org interchange-core@icdevgroup.org
Mon Jul 22 13:45:01 2002


User:      jon
Date:      2002-07-22 17:44:44 GMT
Modified:  lib/Vend Interpolate.pm
Log:
Fix bug in default link template setting, found by Stefan.

Revision  Changes    Path
2.87      +5 -4      interchange/lib/Vend/Interpolate.pm


rev 2.87, prev_rev 2.86
Index: Interpolate.pm
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /var/cvs/interchange/lib/Vend/Interpolate.pm,v
retrieving revision 2.86
retrieving revision 2.87
diff -u -u -r2.86 -r2.87
--- Interpolate.pm	19 Jul 2002 05:07:17 -0000	2.86
+++ Interpolate.pm	22 Jul 2002 17:44:41 -0000	2.87
@@ -1,6 +1,6 @@
 # Vend::Interpolate - Interpret Interchange tags
 #=20
-# $Id: Interpolate.pm,v 2.86 2002/07/19 05:07:17 mheins Exp $
+# $Id: Interpolate.pm,v 2.87 2002/07/22 17:44:41 jon Exp $
 #
 # Copyright (C) 1996-2002 Red Hat, Inc. <interchange@redhat.com>
 #
@@ -27,7 +27,7 @@
 require Exporter;
 @ISA =3D qw(Exporter);
=20
-$VERSION =3D substr(q$Revision: 2.86 $, 10);
+$VERSION =3D substr(q$Revision: 2.87 $, 10);
=20
 @EXPORT =3D qw (
=20
@@ -3638,8 +3638,9 @@
 		$border =3D~ s/\D//g;
 	}
=20
-	$r =3D~ s:\[link[-_]template\]($All)\[/link[-_]template\]::i;
-	$link_template =3D $1 || '<A HREF=3D"$URL$">$ANCHOR$</A>';
+	$r =3D~ s:\[link[-_]template\]($All)\[/link[-_]template\]::i
+		and $link_template =3D $1;
+	$link_template ||=3D q{<A HREF=3D"$URL$">$ANCHOR$</A>};
=20
 	if(! $chunk or $chunk >=3D $total) {
 		return '';