--- a/entities/lib.py Thu Jul 15 12:03:13 2010 +0200
+++ b/entities/lib.py Mon Jul 19 15:37:02 2010 +0200
@@ -48,13 +48,13 @@
@property
def email_of(self):
- return self.reverse_use_email and self.reverse_use_email[0]
+ return self.reverse_use_email and self.reverse_use_email[0] or None
@property
def prefered(self):
return self.prefered_form and self.prefered_form[0] or self
- @deprecated('use .prefered')
+ @deprecated('[3.6] use .prefered')
def canonical_form(self):
return self.prefered_form and self.prefered_form[0] or self
@@ -89,14 +89,6 @@
return self.display_address()
return super(EmailAddress, self).printable_value(attr, value, attrtype, format)
- def after_deletion_path(self):
- """return (path, parameters) which should be used as redirect
- information when this entity is being deleted
- """
- if self.email_of:
- return self.email_of.rest_path(), {}
- return super(EmailAddress, self).after_deletion_path()
-
class Bookmark(AnyEntity):
"""customized class for Bookmark entities"""
@@ -133,12 +125,6 @@
except UnknownProperty:
return u''
- def after_deletion_path(self):
- """return (path, parameters) which should be used as redirect
- information when this entity is being deleted
- """
- return 'view', {}
-
class CWCache(AnyEntity):
"""Cache"""