From 5c99171908fe67afc78e3b64e815de6bfe651e46 Mon Sep 17 00:00:00 2001
From: Gabriel Monnerat <gabriel@tiolive.com>
Date: Wed, 9 Apr 2014 08:35:21 -0700
Subject: [PATCH] erp5_core: Keep erp5 core minimal.

As Event_send is doing nothing, we don't need it. Then, return None is enough when type based method is not found.
---
 product/ERP5/Document/Event.py                |  4 +-
 .../portal_skins/erp5_core/Event_send.xml     | 70 -------------------
 product/ERP5/bootstrap/erp5_core/bt/revision  |  2 +-
 3 files changed, 3 insertions(+), 73 deletions(-)
 delete mode 100644 product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Event_send.xml

diff --git a/product/ERP5/Document/Event.py b/product/ERP5/Document/Event.py
index ba609213df..5eedbfa11f 100644
--- a/product/ERP5/Document/Event.py
+++ b/product/ERP5/Document/Event.py
@@ -162,8 +162,8 @@ class Event(Movement, EmailDocument, AcknowledgeableMixin):
     """
     send_script = self._getTypeBasedMethod('send')
     if send_script is None:
-      raise NotImplementedError("`send` type based method not found. "
-                                "Please update erp5_base and erp5_crm")
+      return
+
     return send_script(
         from_url, to_url, reply_url, subject, body, attachment_format, attachment_list,
         download, **kw
diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Event_send.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Event_send.xml
deleted file mode 100644
index 05c438c349..0000000000
--- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Event_send.xml
+++ /dev/null
@@ -1,70 +0,0 @@
-<?xml version="1.0"?>
-<ZopeData>
-  <record id="1" aka="AAAAAAAAAAE=">
-    <pickle>
-      <global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
-    </pickle>
-    <pickle>
-      <dictionary>
-        <item>
-            <key> <string>Script_magic</string> </key>
-            <value> <int>3</int> </value>
-        </item>
-        <item>
-            <key> <string>_bind_names</string> </key>
-            <value>
-              <object>
-                <klass>
-                  <global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
-                </klass>
-                <tuple/>
-                <state>
-                  <dictionary>
-                    <item>
-                        <key> <string>_asgns</string> </key>
-                        <value>
-                          <dictionary>
-                            <item>
-                                <key> <string>name_container</string> </key>
-                                <value> <string>container</string> </value>
-                            </item>
-                            <item>
-                                <key> <string>name_context</string> </key>
-                                <value> <string>context</string> </value>
-                            </item>
-                            <item>
-                                <key> <string>name_m_self</string> </key>
-                                <value> <string>script</string> </value>
-                            </item>
-                            <item>
-                                <key> <string>name_subpath</string> </key>
-                                <value> <string>traverse_subpath</string> </value>
-                            </item>
-                          </dictionary>
-                        </value>
-                    </item>
-                  </dictionary>
-                </state>
-              </object>
-            </value>
-        </item>
-        <item>
-            <key> <string>_body</string> </key>
-            <value> <string>"""Event send does nothing by default, it has to be implemented for each kind\n
-of event, look at MailMessage_send for example.\n
-"""\n
-pass\n
-</string> </value>
-        </item>
-        <item>
-            <key> <string>_params</string> </key>
-            <value> <string>from_url=None, to_url=None, reply_url=None, subject=None, body=None, attachment_format=None, attachment_list=None, download=None, **kw</string> </value>
-        </item>
-        <item>
-            <key> <string>id</string> </key>
-            <value> <string>Event_send</string> </value>
-        </item>
-      </dictionary>
-    </pickle>
-  </record>
-</ZopeData>
diff --git a/product/ERP5/bootstrap/erp5_core/bt/revision b/product/ERP5/bootstrap/erp5_core/bt/revision
index 71d3b264e9..0382bf898a 100644
--- a/product/ERP5/bootstrap/erp5_core/bt/revision
+++ b/product/ERP5/bootstrap/erp5_core/bt/revision
@@ -1 +1 @@
-41157
\ No newline at end of file
+41158
\ No newline at end of file
-- 
2.30.9