sobjects/hooks.py
branchtls-sprint
changeset 1802 d628defebc17
parent 1398 5fe84a5f7035
child 1977 606923dff11b
--- a/sobjects/hooks.py	Thu May 14 10:24:56 2009 +0200
+++ b/sobjects/hooks.py	Thu May 14 11:38:40 2009 +0200
@@ -15,7 +15,7 @@
     """ensure user logins are stripped"""
     events = ('before_add_entity', 'before_update_entity',)
     accepts = ('CWUser',)
-    
+
     def call(self, session, entity):
         if 'login' in entity and entity['login']:
             entity['login'] = entity['login'].strip()
@@ -30,12 +30,12 @@
                                           {'x': self.beid}, 'x'):
                 session.unsafe_execute('DELETE Bookmark X WHERE X eid %(x)s',
                                        {'x': self.beid}, 'x')
-        
+
 class DelBookmarkedByHook(Hook):
     """ensure user logins are stripped"""
     events = ('after_delete_relation',)
     accepts = ('bookmarked_by',)
-    
+
     def call(self, session, subj, rtype, obj):
         AutoDeleteBookmark(session, beid=subj)
 
@@ -60,4 +60,3 @@
                         fmt = entity.get_value(metaattr)
                     if fmt == 'text/html':
                         entity[attr] = soup2xhtml(value, session.encoding)
-