Update main.py
Browse files
main.py
CHANGED
@@ -99,8 +99,6 @@ app = FastAPI()
|
|
99 |
@app.post("/webhook")
|
100 |
async def webhook(request: Request):
|
101 |
logger.info(f"Received webhook request from {request.client.host}")
|
102 |
-
logger.info(f"{MODEL_CATALOG_WEBHOOK_SECRET}")
|
103 |
-
logger.info(f"{request.headers.get('X-Webhook-Secret')}")
|
104 |
if request.headers.get("X-Webhook-Secret") not in {MODEL_CATALOG_WEBHOOK_SECRET, SIMSHIP_WEBHOOK_SECRET}:
|
105 |
logger.warning("Invalid webhook secret received")
|
106 |
return Response("Invalid secret", status_code=401)
|
|
|
99 |
@app.post("/webhook")
|
100 |
async def webhook(request: Request):
|
101 |
logger.info(f"Received webhook request from {request.client.host}")
|
|
|
|
|
102 |
if request.headers.get("X-Webhook-Secret") not in {MODEL_CATALOG_WEBHOOK_SECRET, SIMSHIP_WEBHOOK_SECRET}:
|
103 |
logger.warning("Invalid webhook secret received")
|
104 |
return Response("Invalid secret", status_code=401)
|