[web/form] Relax condition for non-translating field names
we should test true condition instead of None, so if one raise a ValidationError
using an empty string as 'no-field' marker instead of None, we don't get the PO
file header that gettext likes to return when one attempt to translate an empty
string.
--- a/cubicweb/web/views/formrenderers.py Tue Sep 26 10:46:43 2017 +0200
+++ b/cubicweb/web/views/formrenderers.py Thu Oct 05 17:24:29 2017 +0200
@@ -172,7 +172,7 @@
else:
templstr = u' %s\n'
for field, err in errors:
- if field is None:
+ if not field:
errormsg += templstr % err
else:
errormsg += templstr % '%s: %s' % (req._(field), err)