Skip to content

Commit

Permalink
Merge pull request OpenMS#95 from Arslan-Siraj/main
Browse files Browse the repository at this point in the history
captcha error fixed
  • Loading branch information
Arslan-Siraj authored Nov 14, 2024
2 parents bf5566d + f6f4eee commit 6a9e074
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
4 changes: 3 additions & 1 deletion default-parameters.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,7 @@
"2D-map-intensity-cutoff": 5000,

"example-x-dimension": 10,
"example-y-dimension": 5
"example-y-dimension": 5,

"controllo": false
}
13 changes: 9 additions & 4 deletions src/common/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,10 +228,15 @@ def page_setup(page: str = "") -> dict[str, Any]:
params = render_sidebar(page)

# If run in hosted mode, show captcha as long as it has not been solved
if not "local" in sys.argv:
if "controllo" not in st.session_state:
# Apply captcha by calling the captcha_control function
captcha_control()
#if not "local" in sys.argv:
# if "controllo" not in st.session_state:
# # Apply captcha by calling the captcha_control function
# captcha_control()

# If run in hosted mode, show captcha as long as it has not been solved
if 'controllo' not in st.session_state or params["controllo"] == False:
# Apply captcha by calling the captcha_control function
captcha_control()

return params

Expand Down

0 comments on commit 6a9e074

Please sign in to comment.