Mike Capp created VELOCITY-902: ---------------------------------- Summary: User guide for #set does not match behaviour Key: VELOCITY-902 URL: https://issues.apache.org/jira/browse/VELOCITY-902 Project: Velocity Issue Type: Bug Components: Documentation Affects Versions: 2.0, 2.1.x Reporter: Mike Capp
[http://velocity.apache.org/engine/2.0/user-guide.html#set] and [http://velocity.apache.org/engine/devel/user-guide.html#set] both have about a page of text explaining that {{#set}} will ignore any assignment with a null RHS and suggesting workarounds. However, even using the exact example shown, 2.0 does *not* ignore null RHSs, and the workarounds don't workatall, which as a complete newbie caused me a lot of head-scratching. I can provide my (very simple) test harness and template if necessary, but the following caught my eye while trawling through the [changelog|http://velocity.apache.org/engine/2.0/changes.html]: {quote}Remove directive.set.null.allowed and instead always allow null to be #set to references. This also means removing all NullSetEventHandler code, since it was only in play when nulls were not allowed to be #set. {quote} Which looks as if this was a deliberate change which forgot to update the user docs. I'm all in favour of the change, btw; the old documented behaviour was horrible. I'm just looking for some reassurance that I can rely on it. -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@velocity.apache.org For additional commands, e-mail: dev-h...@velocity.apache.org