diff --git a/product/ERP5Type/Utils.py b/product/ERP5Type/Utils.py
index da0bc9bcb4f01dde679ca73ed9f2ca5b07d45917..e76e66687bd8fb8b3a262a760c0c9f8bae958b23 100644
--- a/product/ERP5Type/Utils.py
+++ b/product/ERP5Type/Utils.py
@@ -134,9 +134,8 @@ def convertToUpperCase(key):
     This function turns an attribute name into
     a method name according to the ERP5 naming conventions
   """
-  if not isinstance(key, str):
-    LOG('ERP5Type.Utils.convertToUpperCase', PROBLEM,
-        'key `%s` is type %s' % (key, type(key)))
+  if not isinstance(key, basestring):
+    raise TypeError, '%s is not a string' % (key,)
   return ''.join([part.capitalize() for part in str(key).split('_')])
 
 UpperCase = convertToUpperCase
@@ -146,9 +145,8 @@ def convertToMixedCase(key):
     This function turns an attribute name into
     a method name according to the ERP5 naming conventions
   """
-  if not isinstance(key, str):
-    LOG('ERP5Type.Utils.convertToMixedCase', PROBLEM,
-        'key `%s` is type %s' % (key, type(key)))
+  if not isinstance(key, basestring):
+    raise TypeError, '%s is not a string' % (key,)
   parts = str(key).split('_', 1)
   if len(parts) == 2:
     parts[1] = convertToUpperCase(parts[1])