Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

update the id prefixes

Kiran Ka958f99802fa
diff --git a/apps/web/app/(ee)/api/bounties/route.ts b/apps/web/app/(ee)/api/bounties/route.ts
index 9c3d80b65d..672e8e18d3 100644
--- a/apps/web/app/(ee)/api/bounties/route.ts
+++ b/apps/web/app/(ee)/api/bounties/route.ts
@@ -61,7 +61,7 @@ export const POST = withWorkspace(async ({ workspace, req }) => {
const bounty = await prisma.$transaction(async (tx) => {
let workflow: Workflow | null = null;
- const bountyId = createId({ prefix: "bounty_" });
+ const bountyId = createId({ prefix: "bnty_" });
// Create a workflow if there is a performance condition
if (condition) {
diff --git a/apps/web/lib/api/create-id.ts b/apps/web/lib/api/create-id.ts
index f924f4d172..9fb82892dc 100644
--- a/apps/web/lib/api/create-id.ts
+++ b/apps/web/lib/api/create-id.ts
@@ -29,8 +29,8 @@ const prefixes = [
"audit_",
"import_",
"grp_",
- "bounty_", // TODO: [bounties] Finalize this
- "bounty_submission_", // TODO: [bounties] Finalize this
+ "bnty_",
+ "bnty_sub_",
"wf_",
] as const;
diff --git a/apps/web/lib/api/workflows/execute-award-bounty-action.ts b/apps/web/lib/api/workflows/execute-award-bounty-action.ts
index b8e050289a..efc645ae5c 100644
--- a/apps/web/lib/api/workflows/execute-award-bounty-action.ts
+++ b/apps/web/lib/api/workflows/execute-award-bounty-action.ts
@@ -88,7 +88,7 @@ export const executeAwardBountyAction = async ({
const bountySubmission = await prisma.bountySubmission.create({
data: {
- id: createId({ prefix: "bounty_submission_" }),
+ id: createId({ prefix: "bnty_sub_" }),
programId: bounty.programId,
partnerId,
bountyId: bounty.id,