Skip to content

Commit

Permalink
Debugging Upstash #7
Browse files Browse the repository at this point in the history
  • Loading branch information
david emioma committed Apr 3, 2024
1 parent 713d315 commit 2a3c00c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/api/cart/[cartItemId]/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export async function PATCH(
//Check if there is a current user
const { user } = await currentUser();

if (!user) {
if (!user || !user.id) {
return new NextResponse("Unauthorized, You need to be logged in.", {
status: 401,
});
Expand Down Expand Up @@ -155,7 +155,7 @@ export async function DELETE(
//Check if there is a current user
const { user } = await currentUser();

if (!user) {
if (!user || !user.id) {
return new NextResponse("Unauthorized, You need to be logged in.", {
status: 401,
});
Expand Down

0 comments on commit 2a3c00c

Please sign in to comment.