Skip to content

Commit 8a49501

Browse files
committed
fix: placeholder image for thumbnails
Signed-off-by: Varun Raj <mailme@varunraj.in>
1 parent ac4233d commit 8a49501

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/components/layouts/RootLayout.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11

2-
import { cn } from "@/lib/utils"
32
import Sidebar from "../shared/Sidebar"
43
import { Toaster } from "../ui/toaster"
54

@@ -16,7 +15,6 @@ export default function RootLayout({ children }: RootLayoutProps) {
1615
{children}
1716
</div>
1817
<Toaster />
19-
2018
</div>
2119
)
2220
}

src/pages/api/immich-proxy/thumbnail/[id].ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,9 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)
4141
// Send the image data
4242
res.send(Buffer.from(imageBuffer))
4343
} catch (error) {
44+
45+
res.redirect("https://placehold.co/400")
4446
console.error('Error:', error)
45-
res.status(500).json({ message: 'Internal Server Error' })
47+
// res.status(500).json({ message: 'Internal Server Error' })
4648
}
4749
}

0 commit comments

Comments
 (0)