Skip to content

Commit 16fe966

Browse files
committed
chore(deps): fix lint issues
1 parent f5deb0f commit 16fe966

3 files changed

Lines changed: 3 additions & 15 deletions

File tree

netlify/functions/sync-now.mts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export default async function handler(
2828
const apiToken = process.env.NETLIFY_API_TOKEN
2929

3030
if (siteId && apiToken) {
31-
const res = await fetch('https://api.netlify.com/api/v1/purge', {
31+
await fetch('https://api.netlify.com/api/v1/purge', {
3232
method: 'POST',
3333
headers: {
3434
Authorization: `Bearer ${apiToken}`,
@@ -39,10 +39,6 @@ export default async function handler(
3939
paths: ['/developers/roadmap']
4040
})
4141
})
42-
} else {
43-
console.warn(
44-
'[sync-now] NETLIFY_SITE_ID or NETLIFY_API_TOKEN not set — skipping CDN cache purge.'
45-
)
4642
}
4743

4844
return new Response(

netlify/functions/sync.mts

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@ import { getStore } from '@netlify/blobs'
22
import { buildSnapshot } from '../../src/linear/build-snapshot.js'
33

44
export default async function handler() {
5-
console.log('[sync] Starting scheduled Linear sync...')
6-
75
const snapshot = await buildSnapshot()
86

97
const store = getStore('roadmap')
@@ -14,7 +12,7 @@ export default async function handler() {
1412
const apiToken = process.env.NETLIFY_API_TOKEN
1513

1614
if (siteId && apiToken) {
17-
const res = await fetch('https://api.netlify.com/api/v1/purge', {
15+
await fetch('https://api.netlify.com/api/v1/purge', {
1816
method: 'POST',
1917
headers: {
2018
Authorization: `Bearer ${apiToken}`,
@@ -25,10 +23,6 @@ export default async function handler() {
2523
paths: ['/developers/roadmap']
2624
})
2725
})
28-
} else {
29-
console.warn(
30-
'[sync] NETLIFY_SITE_ID or NETLIFY_API_TOKEN not set — skipping CDN cache purge.'
31-
)
3226
}
3327
}
3428

src/linear/build-snapshot.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,9 +147,7 @@ async function withRetry<T>(
147147
if (!isTransientError(err) || attempt === retries) throw err
148148
lastErr = err
149149
const wait = delayMs * 2 ** attempt
150-
console.warn(
151-
`[linear] Transient error (attempt ${attempt + 1}/${retries}), retrying in ${wait}ms...`
152-
)
150+
153151
await new Promise((r) => setTimeout(r, wait))
154152
}
155153
}

0 commit comments

Comments
 (0)