server/repository.py
branchstable
changeset 4756 a2c73b272c9b
parent 4719 aaed3f813ef8
child 4776 3bf51379baee
child 4806 4f12f59b1a13
--- a/server/repository.py	Tue Mar 02 15:44:26 2010 +0100
+++ b/server/repository.py	Tue Mar 02 15:57:32 2010 +0100
@@ -105,7 +105,8 @@
     #     skip that for super session (though we can still skip it for internal
     #     sessions). Also we should imo rely on the orm to first fetch existing
     #     entity if any then delete it.
-    if session.is_internal_session:
+    if session.is_internal_session \
+           or not session.vreg.config.is_hook_category_activated('integrity'):
         return
     card = session.schema_rproperty(rtype, eidfrom, eidto, 'cardinality')
     # one may be tented to check for neweids but this may cause more than one