Change update slug fallback to undefined

This commit is contained in:
Tuan Dang
2024-02-08 17:47:58 -08:00
parent 92828b5295
commit 2cc2a91812

View File

@ -142,7 +142,7 @@ export const orgServiceFactory = ({
const org = await orgDAL.updateById(orgId, {
name,
slug: slug ? slugify(slug) : slug,
slug: slug ? slugify(slug) : undefined,
authEnforced
});
if (!org) throw new BadRequestError({ name: "Org not found", message: "Organization not found" });