Commit f40df82e authored by Tres Seaver's avatar Tres Seaver

Collector #1754: Fixed import of 'transaction' in 'zopectl adduser'.

parent 4d3e54b5
...@@ -29,6 +29,9 @@ Zope Changes ...@@ -29,6 +29,9 @@ Zope Changes
Bugs fixed Bugs fixed
- Collector #1754: Fixed import of 'transaction' in
'zopectl adduser' (which wasy dying with a NameError).
- Collector #1750: StructuredText: fixed handling of image URLs - Collector #1750: StructuredText: fixed handling of image URLs
with query string with query string
......
...@@ -39,8 +39,6 @@ import os ...@@ -39,8 +39,6 @@ import os
import sys import sys
import signal import signal
import transaction
import zdaemon import zdaemon
import Zope2.Startup import Zope2.Startup
...@@ -214,9 +212,11 @@ class ZopeCmd(ZDCmd): ...@@ -214,9 +212,11 @@ class ZopeCmd(ZDCmd):
return return
cmdline = self.get_startup_cmd( cmdline = self.get_startup_cmd(
self.options.python , self.options.python ,
'import Zope2; app=Zope2.app();' 'import Zope2; '
'app.acl_users._doAddUser(\'%s\', \'%s\', [\'Manager\'], []);' 'app = Zope2.app(); '
'transaction.commit()' 'app.acl_users._doAddUser(\'%s\', \'%s\', [\'Manager\'], []); '
'import transaction; '
'transaction.commit(); '
) % (name, password) ) % (name, password)
os.system(cmdline) os.system(cmdline)
......
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