Author: croberts
Date: 2011-11-01 18:47:26 +0000 (Tue, 01 Nov 2011)
New Revision: 5103
Modified:
trunk/cumin/python/cumin/objectframe.py
Log:
Addressing BZ 748735 by taking extra care to check the type before checking to see if we
need to truncate the title. For non-string types, don't bother with the len() call.
Modified: trunk/cumin/python/cumin/objectframe.py
===================================================================
--- trunk/cumin/python/cumin/objectframe.py 2011-10-31 20:34:08 UTC (rev 5102)
+++ trunk/cumin/python/cumin/objectframe.py 2011-11-01 18:47:26 UTC (rev 5103)
@@ -295,7 +295,7 @@
def render_title(self, session):
retval = self.parent.render_title(session)
- if retval is not None and len(retval) > 100:
+ if retval is not None and isinstance(retval, str) and len(retval) > 100:
retval = retval[:100] + "..."
return retval
Show replies by date