Commit 9b388235 authored by Romain Courteaud's avatar Romain Courteaud

Raise exception class instead of a string


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@21489 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent bf0be862
......@@ -107,7 +107,7 @@ def PropertyManager_setProperty(self, id, value, type=None):
if type in ('selection', 'multiple selection'):
if not hasattr(self, value):
raise 'Bad Request', 'No select variable %s' % value
raise BadRequest, 'No select variable %s' % value
self._local_properties=getattr(self, '_local_properties', ()) + (
{'id':id, 'type':type, 'select_variable':value},)
if type=='selection':
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment