Yes, definitely a bug. Could you please open a ticket (http://
github.com/dpp/liftweb/issues) and I will take a look at it. And
thanks for the test case!
Cheers Joni
--
You received this message because you are subscribed to the Google Groups "Lift" group.
To post to this group, send email to lif...@googlegroups.com.
To unsubscribe from this group, send email to liftweb+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en.
The fix is on review board now. Should be in master pretty soon. Note,
I made two changes to the test case you provided.
The expected result of example1 is:
{"word":"content","self":"http://localhost:8080/word/
example","term":"example","available":"true"}
The transformation converts XML attributes to fields in resulting JSON
object. The reason for this rule is that it keeps transformation more
"stable". That is, these both will generate structurally equivalent
JSON:
<word>foo</word> -> {"word":"foo"}
<word attr="bar">foo</word> -> {"word":"foo","attr":"bar"}
The expected result of example2 is:
{"word":null,"self":"http://localhost:8080/word/
example","term":"example","available":"true"}
Field "word" is null since there's no content: <word ...></word>
Cheers Joni
On Feb 3, 11:31 pm, Jonathan Ferguson <j...@spiralarm.com> wrote:
> Thanks Joni,
>
> I've opened a ticket http://github.com/dpp/liftweb/issues/issue/323.
>
> Cheers
> Jono
>
> > liftweb+u...@googlegroups.com<liftweb%2Bunsu...@googlegroups.com>