File tree Expand file tree Collapse file tree
packages/web/src/app/[domain]/repos/components Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -110,6 +110,10 @@ export const getColumns = (context: ColumnsContext): ColumnDef<Repo>[] => [
110110 const repo = row . original ;
111111 const codeHostIcon = getCodeHostIcon ( repo . codeHostType ) ;
112112 const repoImageSrc = repo . imageUrl ? getRepoImageSrc ( repo . imageUrl , repo . id ) : undefined ;
113+ // Internal API routes require authentication headers (cookies/API keys) to be passed through.
114+ // Next.js Image Optimization doesn't forward these headers, so we use unoptimized=true
115+ // to bypass the optimization and make direct requests that include auth headers.
116+ const isInternalApiImage = repoImageSrc ?. startsWith ( '/api/' ) ;
113117
114118 return (
115119 < div className = "flex flex-row gap-2 items-center" >
@@ -121,6 +125,7 @@ export const getColumns = (context: ColumnsContext): ColumnDef<Repo>[] => [
121125 width = { 32 }
122126 height = { 32 }
123127 className = "object-cover"
128+ unoptimized = { isInternalApiImage }
124129 />
125130 ) : < Image
126131 src = { codeHostIcon . src }
You can’t perform that action at this time.
0 commit comments