omkar56 commited on
Commit
644ccbc
1 Parent(s): 3b80834

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +1 -1
main.py CHANGED
@@ -16,7 +16,7 @@ security = APIKeyHeader(name="api_key", auto_error=False)
16
 
17
  def get_api_key(api_key: Optional[str] = Depends(security)):
18
  if api_key is None or api_key != API_KEY:
19
- raise HTTPException(status_code=401, error="Unauthorized access")
20
  return api_key
21
 
22
  def format_prompt(message, history):
 
16
 
17
  def get_api_key(api_key: Optional[str] = Depends(security)):
18
  if api_key is None or api_key != API_KEY:
19
+ raise HTTPException(status_code=401, detail="Unauthorized access")
20
  return api_key
21
 
22
  def format_prompt(message, history):