Skip to content

Commit

Permalink
Merge pull request #1497 from brave/fix-referral-headers-download-0.60.x
Browse files Browse the repository at this point in the history
Merge pull request #1493 from brave/fix-referral-headers-download
  • Loading branch information
emerick authored Jan 29, 2019
2 parents f09e62c + 654a8c0 commit 85fbbdb
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions components/brave_referrals/browser/brave_referrals_service.cc
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,10 @@ void BraveReferralsService::Start() {
base::Bind(&BraveReferralsService::GetFirstRunTime,
base::Unretained(this)));

// Periodically fetch referral headers.
// Fetch the referral headers on startup.
FetchReferralHeaders();

// Also, periodically fetch the referral headers.
DCHECK(!fetch_referral_headers_timer_);
fetch_referral_headers_timer_ = std::make_unique<base::RepeatingTimer>();
fetch_referral_headers_timer_->Start(
Expand All @@ -113,8 +116,6 @@ void BraveReferralsService::Start() {
base::Unretained(this)),
base::Bind(&BraveReferralsService::OnReadPromoCodeComplete,
weak_factory_.GetWeakPtr()));
else
FetchReferralHeaders();

initialized_ = true;
}
Expand Down

0 comments on commit 85fbbdb

Please sign in to comment.