Commits

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
location

  • Participants
  • Parent commits e4f615e

Comments (0)

Files changed (1)

File github3/github.py

             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))
 
     @requires_auth