← Back to team overview

launchpad-reviewers team mailing list archive

[Merge] ~ines-almeida/launchpad:remove-repr-from-email-class into launchpad:master

 

Ines Almeida has proposed merging ~ines-almeida/launchpad:remove-repr-from-email-class into launchpad:master.

Commit message:
Remove __repr__ method from EmailAddress class
    
This prevents leaking object details through the object representation itself when the request is 401 Unauthorized.
    
LP:#2065859


Requested reviews:
  Launchpad code reviewers (launchpad-reviewers)

For more details, see:
https://code.launchpad.net/~ines-almeida/launchpad/+git/launchpad/+merge/467175

All tests under the `registry` directory ran successfully.
-- 
Your team Launchpad code reviewers is requested to review the proposed merge of ~ines-almeida/launchpad:remove-repr-from-email-class into launchpad:master.
diff --git a/lib/lp/services/identity/model/emailaddress.py b/lib/lp/services/identity/model/emailaddress.py
index 043a2f6..72e5597 100644
--- a/lib/lp/services/identity/model/emailaddress.py
+++ b/lib/lp/services/identity/model/emailaddress.py
@@ -55,9 +55,6 @@ class EmailAddress(StormBase, HasOwnerMixin):
         self.status = status
         self.person = person
 
-    def __repr__(self):
-        return "<EmailAddress <%s> [%s]>" % (self.email, self.status)
-
     def destroySelf(self):
         """See `IEmailAddress`."""
         # Import this here to avoid circular references.

References