Эх сурвалжийг харах

Use __repr__ if there is no possibility message defined.

Sander Mathijs van Veen 14 жил өмнө
parent
commit
d5c29c2bdc
1 өөрчлөгдсөн 1 нэмэгдсэн , 2 устгасан
  1. 1 2
      src/possibilities.py

+ 1 - 2
src/possibilities.py

@@ -15,8 +15,7 @@ class Possibility(object):
         if self.handler in MESSAGES:
             return MESSAGES[self.handler].format(self.root, *self.args)
 
-        return '<Possibility root="%s" handler=%s args=%s>' \
-                % (self.root, self.handler.func_name, self.args)
+        return self.__repr__()
 
     def __repr__(self):
         return '<Possibility root="%s" handler=%s args=%s>' \