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 email

Kiran Kbcc74cc2fb0b
diff --git a/apps/web/emails/partner-invite.tsx b/apps/web/emails/partner-invite.tsx
index d00783d18a..578b2fbcc3 100644
--- a/apps/web/emails/partner-invite.tsx
+++ b/apps/web/emails/partner-invite.tsx
@@ -17,20 +17,18 @@ import Footer from "./components/footer";
export default function PartnerInvite({
email = "[email protected]",
appName = "Dub.co",
- url = "https://dub.co",
- workspaceUser = "Brendon Urie",
- workspaceUserEmail = "[email protected]",
+ programName = "Cal",
}: {
email: string;
appName: string;
- url: string;
- workspaceUser: string | null;
- workspaceUserEmail: string | null;
+ programName: string;
}) {
+ const url = "https://partners.dub.co";
+
return (
<Html>
<Head />
- <Preview>Sign up for {appName}</Preview>
+ <Preview>Sign up for {programName}</Preview>
<Tailwind>
<Body className="mx-auto my-auto bg-white font-sans">
<Container className="mx-auto my-10 max-w-[500px] rounded border border-solid border-gray-200 px-10 py-5">
@@ -44,7 +42,7 @@ export default function PartnerInvite({
</Section>
<Heading className="mx-0 my-7 p-0 text-center text-xl font-semibold text-black">
- Sign up for {appName}
+ Sign up for {programName}
</Heading>
<Section className="mb-8 text-center">
diff --git a/apps/web/lib/actions/invite-partner.ts b/apps/web/lib/actions/invite-partner.ts
index 949d17f297..6bc434458d 100644
--- a/apps/web/lib/actions/invite-partner.ts
+++ b/apps/web/lib/actions/invite-partner.ts
@@ -23,7 +23,7 @@ export const invitePartnerAction = authActionClient
const { workspace } = ctx;
const { name, email, linkId, programId } = parsedInput;
- await Promise.all([
+ const [program, _] = await Promise.all([
getProgramOrThrow({
workspaceId: workspace.id,
programId,
@@ -63,10 +63,8 @@ export const invitePartnerAction = authActionClient
email,
react: PartnerInvite({
email,
- appName: process.env.NEXT_PUBLIC_APP_NAME as string,
- url: `https://refer.dub.co/${workspace.slug}`,
- workspaceUser: ctx.user.name || null,
- workspaceUserEmail: ctx.user.email || null,
+ appName: `${process.env.NEXT_PUBLIC_APP_NAME}`,
+ programName: program.name,
}),
});