Spaces:
Sleeping
Sleeping
Update src/streamlit_app.py
Browse files- src/streamlit_app.py +2 -4
src/streamlit_app.py
CHANGED
|
@@ -21,8 +21,8 @@ st.set_page_config(
|
|
| 21 |
initial_sidebar_state="expanded"
|
| 22 |
)
|
| 23 |
|
| 24 |
-
#
|
| 25 |
-
API_BASE_URL = "https://ritesh1035-fp-backend.hf.space"
|
| 26 |
|
| 27 |
# Initialize session state for authentication - with proper persistence
|
| 28 |
def init_session_state():
|
|
@@ -54,8 +54,6 @@ def init_session_state():
|
|
| 54 |
if 'user_email' not in st.session_state:
|
| 55 |
st.session_state.user_email = None
|
| 56 |
|
| 57 |
-
# No longer needed - using radio toggle instead
|
| 58 |
-
|
| 59 |
# Initialize session state
|
| 60 |
init_session_state()
|
| 61 |
|
|
|
|
| 21 |
initial_sidebar_state="expanded"
|
| 22 |
)
|
| 23 |
|
| 24 |
+
# Get backend URL from environment variable (HF Secrets)
|
| 25 |
+
API_BASE_URL = os.getenv("API_BASE_URL", "https://ritesh1035-fp-backend.hf.space")
|
| 26 |
|
| 27 |
# Initialize session state for authentication - with proper persistence
|
| 28 |
def init_session_state():
|
|
|
|
| 54 |
if 'user_email' not in st.session_state:
|
| 55 |
st.session_state.user_email = None
|
| 56 |
|
|
|
|
|
|
|
| 57 |
# Initialize session state
|
| 58 |
init_session_state()
|
| 59 |
|