1. Ian Cordasco
  2. github3.py


Ian Cordasco  committed b051232

Change GitHub's repr

If someone has called GitHub with authentication parameters or logged in,
display the name they decided to use. Otherwise, just display the faux memory

  • Participants
  • Parent commits e4f615e
  • Branches master

Comments (0)

Files changed (1)

File github3/github.py

View file
             self.login(login, password)
     def __repr__(self):
+        if self._session.auth:
+            return '<GitHub [{0[0]}]>'.format(self._session.auth)
         return '<GitHub at 0x{0:x}>'.format(id(self))