HoangHa commited on
Commit
a4b5d04
1 Parent(s): 6a05d5b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -29,7 +29,7 @@ openai_key = ""
29
  # Check if the toggle is on
30
  if api_toggle:
31
  # If the toggle is on, access the API key from secrets
32
- openai_key = os.environ.get("OPENAI_API_KEY")
33
  openai.api_key = openai_key
34
  else:
35
  # If the toggle is off, allow the user to input the API key
 
29
  # Check if the toggle is on
30
  if api_toggle:
31
  # If the toggle is on, access the API key from secrets
32
+ openai_key = os.getenv("OPENAI_API_KEY")
33
  openai.api_key = openai_key
34
  else:
35
  # If the toggle is off, allow the user to input the API key