Skip to content

Commit 263212c

Browse files
committed
fix: album creation flow
Signed-off-by: Varun Raj <varun@skcript.com>
1 parent aef4e6e commit 263212c

File tree

4 files changed

+10
-9
lines changed

4 files changed

+10
-9
lines changed

src/config/constants/sidebarNavs.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
import { GalleryHorizontal, GalleryVerticalEnd, Image as ImageIcon, MapPin, MapPinX, Rewind, Search, User } from "lucide-react";
22

33
export const sidebarNavs = [
4-
{
5-
title: "Rewind 2024",
6-
link: "/rewind",
7-
icon: <Rewind className="h-4 w-4" />,
8-
},
4+
// {
5+
// title: "Rewind 2024",
6+
// link: "/rewind",
7+
// icon: <Rewind className="h-4 w-4" />,
8+
// },
99
{
1010
title: "Find Assets",
1111
link: "/find",

src/lib/api.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ export class APIError extends Error {
1919
}
2020

2121
const handleErrors = (error: AxiosError | any) => {
22-
2322
let errorObject = {}
2423
if (error.response && error.response.data) {
2524
return Promise.reject({

src/pages/albums/potential-albums.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,8 @@ export default function PotentialAlbums() {
7979
});
8080
const newAssets = contextState.assets.filter(a => !contextState.selectedIds.includes(a.id));
8181
updateContext({ selectedIds: [], assets: newAssets });
82+
}).catch((error) => {
83+
console.log("Error", error);
8284
})
8385
}
8486

src/pages/api/immich-proxy/[...path].ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)
2828
res.setHeader(key, value)
2929
})
3030

31-
// Stream the response body
32-
const reader = response.body?.getReader()
33-
if (reader) {
31+
// Only stream the response body if it exists and has content
32+
if (response.body) {
33+
const reader = response.body.getReader()
3434
while (true) {
3535
const { done, value } = await reader.read()
3636
if (done) break

0 commit comments

Comments
 (0)