Skip to content

Commit

Permalink
Do not redirect to anchor
Browse files Browse the repository at this point in the history
  • Loading branch information
eloquence committed Mar 11, 2022
1 parent 61eb4ba commit 540a693
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions securedrop/source_app/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ def submit(logged_in_source: SourceUser) -> werkzeug.Response:
flash(gettext(
"Your first message must be at least {} characters long.".format(min_len)),
"error")
return redirect(f"{url_for('main.lookup')}#flashed")
return redirect(url_for('main.lookup'))

codenames_rejected = InstanceConfig.get_default().reject_message_with_codename
if codenames_rejected and codename_detected(msg, session['new_user_codename']):
Expand All @@ -215,7 +215,7 @@ def submit(logged_in_source: SourceUser) -> werkzeug.Response:
escape(gettext("Keep your codename secret, and use it to log in later"
" to check for replies."))
)), "error")
return redirect(f"{url_for('main.lookup')}#flashed")
return redirect(url_for('main.lookup'))

if not os.path.exists(Storage.get_default().path(logged_in_source.filesystem_id)):
current_app.logger.debug("Store directory not found for source '{}', creating one."
Expand Down

0 comments on commit 540a693

Please sign in to comment.