velocity-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wgl...@apache.org
Subject svn commit: r544361 - /velocity/engine/trunk/src/java/org/apache/velocity/Template.java
Date Tue, 05 Jun 2007 04:02:22 GMT
Author: wglass
Date: Mon Jun  4 21:02:21 2007
New Revision: 544361

URL: http://svn.apache.org/viewvc?view=rev&rev=544361
Log:
set the current resource during template initialization. VELOCITY-546.  Thanks to Adam Heath.

Modified:
    velocity/engine/trunk/src/java/org/apache/velocity/Template.java

Modified: velocity/engine/trunk/src/java/org/apache/velocity/Template.java
URL: http://svn.apache.org/viewvc/velocity/engine/trunk/src/java/org/apache/velocity/Template.java?view=diff&rev=544361&r1=544360&r2=544361
==============================================================================
--- velocity/engine/trunk/src/java/org/apache/velocity/Template.java (original)
+++ velocity/engine/trunk/src/java/org/apache/velocity/Template.java Mon Jun  4 21:02:21 2007
@@ -191,6 +191,7 @@
              */
 
             ica.pushCurrentTemplateName( name );
+            ica.setCurrentResource( this );
 
             /*
              *  init the AST
@@ -206,6 +207,7 @@
              */
 
             ica.popCurrentTemplateName();
+            ica.setCurrentResource( null );
         }
 
     }



Mime
View raw message