Closed Chris00 closed 10 years ago
Other text constructs that, at the moment, are parsed as string
are atom:rights
, atom:subtitle
, and atom:title
. None of the feeds of the planet use (X)HTML for these so I am not sure one should change... (but it would be more robust).
I think in this case, we should either use text_construct
or convert with XML.to_string
(for avoid to raise an exception).
If I follow you well, you mean you would prefer that HTML would be left unparsed? thus the constructor would be Html of string
and if the feed does not follow the spec and has structured contend parsed by Xmlm
, we convert it back to a string? That's an option I am fine with.
Note that no exception is ever raised. If the conversion fails, [Leaf d]
is left untouched.
Yes, I think that Syndic does not have to deal with the content, but just the form.
That makes sense. I'll change the PR accordingly.
What about the 3 other fields?
Same as summary
with text_construct
and Html of string
, no ?
Yep.
This small factorization makes it easier to use for other text construct fields if it is deemed necessary.