changeset 1895:46e859ee4d2e

edit: set request.rev to default after saving for further actions
author Reimar Bauer <rb.proj AT googlemail DOT com>
date Sun, 18 Mar 2007 21:46:32 +0100
parents 5ae7a098f6e4
children 1de612a8c553
files MoinMoin/PageEditor.py MoinMoin/action/edit.py
diffstat 2 files changed, 2 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/PageEditor.py	Sun Mar 18 20:31:42 2007 +0100
+++ b/MoinMoin/PageEditor.py	Sun Mar 18 21:46:32 2007 +0100
@@ -996,12 +996,6 @@
             f.write(revstr+'\n')
             f.close()
 
-            # we need to update request.rev here to get the right revision used for
-            # action links rendered by the final send_page() call (#preview display)
-            # XXX this is not the right place to do this as you could use this function
-            # to save any other page than the currently displayed one
-            #request.rev = rev
-
             if not deleted:
                 # save to page file
                 pagefile = os.path.join(revdir, revstr)
--- a/MoinMoin/action/edit.py	Sun Mar 18 20:31:42 2007 +0100
+++ b/MoinMoin/action/edit.py	Sun Mar 18 21:46:32 2007 +0100
@@ -171,5 +171,7 @@
         if backto:
             pg = Page(request, backto)
 
+        # sets revision number to default for further actions
+        request.rev = 0
         pg.send_page(msg=savemsg)