Code

Make HTMLProperty report actual classname in repr().
authorstefan <stefan@57a73879-2fb5-44c3-a270-3262357dd7e2>
Thu, 4 Nov 2010 22:34:20 +0000 (22:34 +0000)
committerstefan <stefan@57a73879-2fb5-44c3-a270-3262357dd7e2>
Thu, 4 Nov 2010 22:34:20 +0000 (22:34 +0000)
git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/roundup/trunk@4572 57a73879-2fb5-44c3-a270-3262357dd7e2

roundup/cgi/templating.py

index 079305bfbfb95f271faf176a1f376ca4fa0f8b67..510aa6148acf8845636528303770108f4cfe08d7 100644 (file)
@@ -1289,8 +1289,9 @@ class HTMLProperty(HTMLInputMixin, HTMLPermissions):
         HTMLInputMixin.__init__(self)
 
     def __repr__(self):
-        return '<HTMLProperty(0x%x) %s %r %r>'%(id(self), self._formname,
-            self._prop, self._value)
+        classname = self.__class__.__name__
+        return '<%s(0x%x) %s %r %r>'%(classname, id(self), self._formname,
+                                      self._prop, self._value)
     def __str__(self):
         return self.plain()
     def __cmp__(self, other):