You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by bw...@apache.org on 2006/04/22 09:42:57 UTC

svn commit: r396094 - /tapestry/tapestry4/branches/branch-3-0/framework/src/org/apache/tapestry/components/Foreach.java

Author: bwallace
Date: Sat Apr 22 00:42:55 2006
New Revision: 396094

URL: http://svn.apache.org/viewcvs?rev=396094&view=rev
Log:
[TAPESTRY-295] Moved hasNext() call to end of while loop.

Modified:
    tapestry/tapestry4/branches/branch-3-0/framework/src/org/apache/tapestry/components/Foreach.java

Modified: tapestry/tapestry4/branches/branch-3-0/framework/src/org/apache/tapestry/components/Foreach.java
URL: http://svn.apache.org/viewcvs/tapestry/tapestry4/branches/branch-3-0/framework/src/org/apache/tapestry/components/Foreach.java?rev=396094&r1=396093&r2=396094&view=diff
==============================================================================
--- tapestry/tapestry4/branches/branch-3-0/framework/src/org/apache/tapestry/components/Foreach.java (original)
+++ tapestry/tapestry4/branches/branch-3-0/framework/src/org/apache/tapestry/components/Foreach.java Sat Apr 22 00:42:55 2006
@@ -105,7 +105,6 @@
             while (hasNext)
             {
                 _value = dataSource.next();
-                hasNext = dataSource.hasNext();
 
                 if (indexBinding != null)
                     indexBinding.setInt(_index);
@@ -125,6 +124,7 @@
                     writer.end();
 
                 _index++;
+                hasNext = dataSource.hasNext();
             }
         }
         finally



---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-dev-help@jakarta.apache.org