fix: Show toast after copy referral link + change icon to "gift" (#16618)
Co-authored-by: zomars <[email protected]>
This commit is contained in:
1 parent
d9133cb395
commit
f2b3e620b4
9 files changed
+41
-17
No files matched your search
@@ -16,9 +16,10 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)
|
||||
}
|
||||
|
||||
try {
|
||||
return await dub.links.get({
|
||||
const { shortLink } = await dub.links.get({
|
||||
externalId: `ext_${session.user.id.toString()}`,
|
||||
});
|
||||
return res.status(200).json({ shortLink });
|
||||
} catch (error) {
|
||||
console.log("Referral link not found, creating...");
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user