From 5bd6ee52eb27e7ab5e288f66f05b2f8ebaf1a66a Mon Sep 17 00:00:00 2001 From: Soner Yuksel Date: Fri, 6 Oct 2023 13:53:34 -0400 Subject: [PATCH] Adding referral code token atribution for release --- App/iOS/Delegates/SceneDelegate.swift | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/App/iOS/Delegates/SceneDelegate.swift b/App/iOS/Delegates/SceneDelegate.swift index 55ec089ee3e..2f5742160e1 100644 --- a/App/iOS/Delegates/SceneDelegate.swift +++ b/App/iOS/Delegates/SceneDelegate.swift @@ -546,7 +546,7 @@ extension BrowserViewController { } } - private func generateReferralCode(attributionData: AdAttributionData?, fetchError: Error?) -> String { + private func generateReferralCode(attributionData: AdAttributionData?, fetchError: Error?) -> String? { // Checking referral code from User Referral program exists If not send 001 // Prefix this code with BRV for organic iOS installs var referralCode = "BRV\(UserReferralProgram.getReferralCode() ?? "001")" @@ -560,7 +560,7 @@ extension BrowserViewController { } } - return referralCode + return AppConstants.buildChannel == .release ? referralCode : UserReferralProgram.getReferralCode() } private func performProgramReferralLookup(_ urp: UserReferralProgram, refCode: String?) {