This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "heist".
The branch, master has been updated
via d5f3f294f08744e1328462c7ed897fad49affe86 (commit)
from b42e0ac6169892556c8d43c82a46d24f4bcbd2e6 (commit)
Summary of changes:
src/Text/Templating/Heist/Internal.hs | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit d5f3f294f08744e1328462c7ed897fad49affe86
Author: Gregory Collins <[email protected]>
Date: Tue Oct 19 22:40:14 2010 +0200
Hopefully fix issue 21, where attribute substitutions were not being
performed when calling splices
diff --git a/src/Text/Templating/Heist/Internal.hs
b/src/Text/Templating/Heist/Internal.hs
index 45b7a92..f4dcea2 100644
--- a/src/Text/Templating/Heist/Internal.hs
+++ b/src/Text/Templating/Heist/Internal.hs
@@ -233,14 +233,15 @@ getContext = getsTS _curContext
-- | Performs splice processing on a single node.
runNode :: Monad m => Node -> Splice m
runNode n@(X.Text _) = return [n]
-runNode n@(X.Element nm at ch) = do
+runNode (X.Element nm at ch) = do
+ newAtts <- mapM attSubst at
+ let n = X.Element nm newAtts ch
s <- liftM (lookupSplice nm) getTS
- maybe runChildren (recurseSplice n) s
+ maybe (runChildren newAtts) (recurseSplice n) s
where
- runChildren = do
+ runChildren newAtts = do
newKids <- runNodeList ch
- newAtts <- mapM attSubst at
return [X.Element nm newAtts newKids]
-----------------------------------------------------------------------
hooks/post-receive
--
heist
_______________________________________________
Snap mailing list
[email protected]
http://mailman-mail5.webfaction.com/listinfo/snap