Skip to content

Commit e59d678

Browse files
committed
Optional org chain to not break local dev env
1 parent 7a02b07 commit e59d678

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/backend/src/utils/car.utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export const getCurrentCar = async (req: Request, _res: Response, next: NextFunc
1313
const car = await prisma.car.findUnique({
1414
where: {
1515
carId,
16-
wbsElement: { organizationId: req.organization.organizationId }
16+
wbsElement: { organizationId: req.organization?.organizationId }
1717
},
1818
include: { wbsElement: true }
1919
});

0 commit comments

Comments
 (0)