[Zope3-checkins] CVS: Zope3/src/zope/app/browser/form - widget.py:1.25

Jim Fulton jim@zope.com
Wed, 26 Mar 2003 10:26:22 -0500


Update of /cvs-repository/Zope3/src/zope/app/browser/form
In directory cvs.zope.org:/tmp/cvs-serv26588/src/zope/app/browser/form

Modified Files:
	widget.py 
Log Message:
Fixed bug in handling the case when a translation can't be found.



=== Zope3/src/zope/app/browser/form/widget.py 1.24 => 1.25 ===
--- Zope3/src/zope/app/browser/form/widget.py:1.24	Wed Mar 26 06:28:53 2003
+++ Zope3/src/zope/app/browser/form/widget.py	Wed Mar 26 10:26:21 2003
@@ -126,6 +126,8 @@
     def label(self):
         ts = getService(self.context.context, "Translation")
         title = ts.translate("zope", self.title, context=self.request)
+        if title is None:
+            title = self.title
         return '<label for="%s">%s</label>' % (
             self.name,
             title,