Skip to content

Commit

Permalink
check in setup oage captcha solve or not
Browse files Browse the repository at this point in the history
  • Loading branch information
Arslan-Siraj committed Nov 13, 2024
1 parent d6c4970 commit e8dce16
Showing 1 changed file with 9 additions and 4 deletions.
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 e8dce16

Please sign in to comment.