Skip to content

Commit ff186b6

Browse files
committed
refactor: improve formatting of warning log in stale fallback for GitHub content fetching
1 parent ff2b8a4 commit ff186b6

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

src/utils/documents.server.ts

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -414,12 +414,15 @@ export async function fetchRepoFile(
414414
ttl: DOC_FILE_CACHE_TTL_MS,
415415
shouldFallbackToStale: isRecoverableGitHubContentError,
416416
onStaleFallback: (error) => {
417-
console.warn('[fetchRepoFile] Serving stale cached file after GitHub fetch failure:', {
418-
repoPair,
419-
ref,
420-
filepath,
421-
message: error instanceof Error ? error.message : String(error),
422-
})
417+
console.warn(
418+
'[fetchRepoFile] Serving stale cached file after GitHub fetch failure:',
419+
{
420+
repoPair,
421+
ref,
422+
filepath,
423+
message: error instanceof Error ? error.message : String(error),
424+
},
425+
)
423426
},
424427
fn: async () => {
425428
const maxDepth = 4

0 commit comments

Comments
 (0)