[Pkg-bazaar-commits] ./bzr/unstable r585: - make RemoteBranch.__str__ more robust

Martin Pool mbp at sourcefrog.net
Fri Apr 10 08:19:47 UTC 2009


------------------------------------------------------------
revno: 585
committer: Martin Pool <mbp at sourcefrog.net>
timestamp: Mon 2005-05-30 11:57:04 +1000
message:
  - make RemoteBranch.__str__ more robust
modified:
  bzrlib/remotebranch.py
-------------- next part --------------
=== modified file 'bzrlib/remotebranch.py'
--- a/bzrlib/remotebranch.py	2005-05-30 01:37:52 +0000
+++ b/bzrlib/remotebranch.py	2005-05-30 01:57:04 +0000
@@ -115,7 +115,8 @@
         self.text_store = RemoteStore(baseurl + '/.bzr/text-store/')
 
     def __str__(self):
-        return '%s(%r)' % (self.__class__.__name__, self.baseurl)
+        b = getattr(self, 'baseurl', 'undefined')
+        return '%s(%r)' % (self.__class__.__name__, b)
 
     __repr__ = __str__
 



More information about the Pkg-bazaar-commits mailing list