Permalink
Browse files

Use standard naming

svn path=/plone.session/trunk/; revision=13858
  • Loading branch information...
1 parent 8eebb80 commit 63e91dd9b474a858acbcc93feae5e4c80304f576 @wichert wichert committed Mar 25, 2007
Showing with 7 additions and 6 deletions.
  1. +2 −2 plone/session/__init__.py
  2. +4 −3 plone/session/plugins/session.py
  3. +1 −1 plone/session/plugins/session.zpt
View
4 plone/session/__init__.py
@@ -9,7 +9,7 @@
def initialize(context):
context.registerClass(session.SessionPlugin,
permission = add_user_folders,
- constructors = (session.manage_addSessionPlugin,
- session.addSessionPlugin),
+ constructors = (session.manage_addSessionPluginForm,
+ session.manage_addSessionPlugin),
visibility = None)
View
7 plone/session/plugins/session.py
@@ -18,15 +18,16 @@ def postonly(func):
from Products.PluggableAuthService.permissions import ManageUsers
-manage_addSessionPlugin = PageTemplateFile('session', globals())
+manage_addSessionPluginForm = PageTemplateFile('session', globals())
-def addSessionPlugin(dispatcher, id, title=None, path='/', REQUEST=None):
+def manage_addSessionPlugin(dispatcher, id, title=None, path='/', REQUEST=None):
"""Add a session plugin."""
sp=SessionPlugin(id, title=title, path=path)
dispatcher._setObject(id, sp)
- REQUEST.RESPONSE.redirect( '%s/manage_workspace?'
+ if REQUEST is not None:
+ REQUEST.RESPONSE.redirect('%s/manage_workspace?'
'manage_tabs_message=Session+plugin+created.' %
dispatcher.absolute_url())
View
2 plone/session/plugins/session.zpt
@@ -7,7 +7,7 @@
plone.session is a session plugin which does not use Zope sessions.
</p>
-<form action="addSessionPlugin" method="post"
+<form action="manage_addSessionPlugin" method="post"
enctype="multipart/form-data">
<table cellspacing="0" cellpadding="2" border="0">
<tr>

0 comments on commit 63e91dd

Please sign in to comment.