rairo commited on
Commit
f889b74
·
1 Parent(s): 418b3b9

Update data_test2.py

Browse files
Files changed (1) hide show
  1. data_test2.py +2 -2
data_test2.py CHANGED
@@ -1,6 +1,6 @@
1
  # Get the token from the URL
2
  load_dotenv()
3
- secret = 01bb7cb8c56a57ee77e6ec3d851572fd #os.getenv("SECRET")
4
 
5
  params = st.experimental_get_query_params()
6
  token = params["token"][0]
@@ -22,7 +22,7 @@ companynreg = decoded["payload"]["companynreg"]
22
  email = decoded["payload"]["email"]
23
 
24
  # Connect to the database
25
- cnx = mysql.connector.connect(user=st.secrets.user, password=st.secrets.password, host=st.secrets.host, database=st.secrets.database)
26
  cursor = cnx.cursor()
27
 
28
  # Get all financial data for this company
 
1
  # Get the token from the URL
2
  load_dotenv()
3
+ secret = os.environ['SECRET']
4
 
5
  params = st.experimental_get_query_params()
6
  token = params["token"][0]
 
22
  email = decoded["payload"]["email"]
23
 
24
  # Connect to the database
25
+ cnx = mysql.connector.connect(user=os.environ['USER'], password=os.environ['PASSWORD'], host=os.environ['HOST'], database=os.environ['DATABASE'])
26
  cursor = cnx.cursor()
27
 
28
  # Get all financial data for this company