Skip to content

Commit a5d5141

Browse files
author
Gordon B. McMillan
committed
Simple optimization.
1 parent 0012e75 commit a5d5141

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

roundup/cgi_client.py

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
# BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
1616
# SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
1717
#
18-
# $Id: cgi_client.py,v 1.147 2002-07-30 08:22:38 richard Exp $
18+
# $Id: cgi_client.py,v 1.148 2002-07-30 16:09:11 gmcm Exp $
1919

2020
__doc__ = """
2121
WWW request handler (also used in the stand-alone server).
@@ -1332,8 +1332,9 @@ def newuser_action(self, message=None):
13321332
" %(action)s.")%{'action': 'registration'}
13331333

13341334
# re-open the database as "admin"
1335-
self.opendb('admin')
1336-
1335+
if self.user != 'admin':
1336+
self.opendb('admin')
1337+
13371338
# create the new user
13381339
cl = self.db.user
13391340
try:
@@ -1691,6 +1692,12 @@ def parsePropsFromForm(db, cl, form, nodeid=0, num_re=re.compile('^\d+$')):
16911692

16921693
#
16931694
# $Log: not supported by cvs2svn $
1695+
# Revision 1.147 2002/07/30 08:22:38 richard
1696+
# Session storage in the hyperdb was horribly, horribly inefficient. We use
1697+
# a simple anydbm wrapper now - which could be overridden by the metakit
1698+
# backend or RDB backend if necessary.
1699+
# Much, much better.
1700+
#
16941701
# Revision 1.146 2002/07/30 05:27:30 richard
16951702
# nicer error messages, and a bugfix
16961703
#

0 commit comments

Comments
 (0)