mirror of
https://github.com/simstudioai/sim.git
synced 2026-09-24 15:45:35 +08:00
fix(gmail): fix unauthorized gmail polling
This commit is contained in:
@@ -40,10 +40,9 @@ export async function GET(request: NextRequest) {
|
||||
|
||||
try {
|
||||
const authHeader = request.headers.get('authorization')
|
||||
const webhookSecret = process.env.WEBHOOK_POLLING_SECRET
|
||||
const webhookSecret = process.env.CRON_SECRET || process.env.WEBHOOK_POLLING_SECRET
|
||||
|
||||
if (!webhookSecret) {
|
||||
logger.warn(`WEBHOOK_POLLING_SECRET is not set`)
|
||||
return new NextResponse('Configuration error: Webhook secret is not set', { status: 500 })
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user