Display "No Content" instead of a parse error when there is no content.

This commit is contained in:
Aldo Cortesi 2012-08-30 12:51:04 +12:00
parent a2f9ca1d4d
commit 71ae158d7b

View File

@ -357,6 +357,8 @@ def get_content_view(viewmode, hdrItems, content, limit, logfunc):
""" """
Returns a (msg, body) tuple. Returns a (msg, body) tuple.
""" """
if not content:
return ("No content", "")
msg = [] msg = []
hdrs = flow.ODictCaseless([list(i) for i in hdrItems]) hdrs = flow.ODictCaseless([list(i) for i in hdrItems])