Skip to content

Commit 4a4099c

Browse files
committed
:s/referer/referrer/g
1 parent b564bc7 commit 4a4099c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docs/activities/Development_Guides.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -930,7 +930,7 @@ When a user clicks a shared link, your activity will launch with referral data a
930930
// Early in your activity's initialization
931931
async function handleReferral() {
932932
// Validate the referral data
933-
if (!DiscordRPC.customId || !DiscordRPC.refererId) {
933+
if (!DiscordRPC.customId || !DiscordRPC.referrerId) {
934934
return;
935935
}
936936

@@ -943,15 +943,15 @@ async function handleReferral() {
943943
}
944944

945945
// Prevent self-referrals
946-
if (DiscordRPC.refererId === currentUserId) {
946+
if (DiscordRPC.referrerId === currentUserId) {
947947
console.log('Self-referrals not allowed');
948948
return;
949949
}
950950

951951
// Grant rewards to both users
952952
await grantRewards({
953953
promotionId: DiscordRPC.customId,
954-
refererId: DiscordRPC.refererId,
954+
referrerId: DiscordRPC.referrerId,
955955
newUserId: currentUserId
956956
});
957957
} catch (error) {

0 commit comments

Comments
 (0)