Skip to content

Commit faa85d5

Browse files
committed
fix: use request.full_path for login redirect's next param
1 parent dddcc4e commit faa85d5

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

otterwiki/wiki.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
make_response,
2020
redirect,
2121
render_template,
22+
request,
2223
send_file,
2324
url_for,
2425
)
@@ -512,7 +513,7 @@ def view(self):
512513
toast(
513514
"You lack the permissions to access this wiki. Please login."
514515
)
515-
return redirect(url_for("login", next="/"+self.pagename_full))
516+
return redirect(url_for("login", next=request.full_path))
516517
# handle case that page doesn't exists
517518
self.exists_or_404()
518519

0 commit comments

Comments
 (0)