Commit 86bcf70b authored by Vincent Pelletier's avatar Vincent Pelletier

Person_createUserPreference: Move imports to script beginning.

parent 10773ebe
from zExceptions import Unauthorized
from Products.ERP5Type.Message import translateString
if REQUEST is not None:
from zExceptions import Unauthorized
raise Unauthorized(script.getId())
portal = context.getPortalObject()
......@@ -10,7 +11,6 @@ if not context.getReference():
# noop in case if invoked on non loggable object
return
from Products.ERP5Type.Message import translateString
preference = portal.portal_preferences.createPreferenceForUser(
context.getReference(), enable=True)
......
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