Odd missing values problem

Chris <[email protected]>
Newsgroups gmane.comp.web.freemarker.user
Message-ID <[email protected]>
I've tried adding each of these expressions to my template:

${item.publication!}
${item.publication!""}
${item.publication!"foo"}

For each, I get an error like this:
[ERROR: item.publication! evaluated to null string.]

item.publication returns a TemplateScalarModel, and the .getAsString() 
method returns a null.

What am I doing wrong?

I did add the "missing values" example from the manual to the top of the 
page and it works correctly:

${mouse!"No mouse."}
<#assign mouse="Jerry">
${mouse!"No mouse."}

No mouse.
Jerry


------------------------------------------------------------------------------
Protect Your Site and Customers from Malware Attacks
Learn about various malware tactics and how to avoid them. Understand 
malware threats, the impact they can have on your business, and how you 
can protect your company and customers by using code signing.
http://p.sf.net/sfu/oracle-sfdevnl
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.