# HG changeset patch # User Goffi # Date 1453202498 -3600 # Node ID 602a47ccc07c171e66da0241f02bf0c9a8328cf8 # Parent cf53e3cc702a74ea73f1d325a13ceedfec8e6be0 plugin XEP-0277: removed cleanXHTML on output data: - while it is mandatory to clean input data, output data sent by frontends should and need to be clean - cleaning all output data means that we can't send be sure that all the XHTML we send is not modified - it's a waste of resources as cleaning today reparse the data with lxml - behaviour may change in the future (e.g. having an option to use cleaning on output data) diff -r cf53e3cc702a -r 602a47ccc07c src/plugins/plugin_xep_0277.py --- a/src/plugins/plugin_xep_0277.py Tue Jan 19 12:08:38 2016 +0100 +++ b/src/plugins/plugin_xep_0277.py Tue Jan 19 12:21:38 2016 +0100 @@ -364,8 +364,6 @@ converted = yield synt.convert(data[attr], synt.getCurrentSyntax(profile), "XHTML") if '{}_xhtml'.format(elem_name) in data: raise failure.Failure(exceptions.DataError(_("Can't have xhtml and rich content at the same time"))) - else: # clean the XHTML input - converted = yield synt.cleanXHTML(data[attr]) xml_content = u'
{converted}
'.format( ns=NS_XHTML,