diff MoinMoin/themes/__init__.py @ 2933:08007ac96dda

Issue #483 and #482
author Aabhas Majumdar <majumdaraabhas@gmail.com>
date Mon, 23 Feb 2015 00:03:32 +0530
parents ec34b7876eeb
children 456c68761e96
line wrap: on
line diff
--- a/MoinMoin/themes/__init__.py	Fri Feb 13 21:14:01 2015 +0100
+++ b/MoinMoin/themes/__init__.py	Mon Feb 23 00:03:32 2015 +0530
@@ -439,7 +439,7 @@
 
     # Properties ##############################################################
 
-    def login_url(self):
+    def login_url(self, next_url=None):
         """
         Return URL usable for user login
 
@@ -448,9 +448,9 @@
         """
         url = None
         if self.cfg.auth_login_inputs == ['special_no_input']:
-            url = url_for('frontend.login', login=1)
+            url = url_for('frontend.login', login=1, next=next_url)
         if self.cfg.auth_have_login:
-            url = url or url_for('frontend.login')
+            url = url or url_for('frontend.login', next=next_url)
         return url
 
     def get_fqnames(self, fqname):