diff --git a/app/brave_generated_resources.grd b/app/brave_generated_resources.grd index 80633a5436cb..679a48387302 100644 --- a/app/brave_generated_resources.grd +++ b/app/brave_generated_resources.grd @@ -152,7 +152,7 @@ Stats - Ledger + Brave Payments Widevine is not installed @@ -173,7 +173,7 @@ By installing this extension, you are agreeing to the Google Widevine Terms of U - Brave + Brave (old) Imported From Brave diff --git a/browser/importer/brave_profile_writer.cc b/browser/importer/brave_profile_writer.cc index 7033dc873c04..45604cf3a929 100644 --- a/browser/importer/brave_profile_writer.cc +++ b/browser/importer/brave_profile_writer.cc @@ -211,11 +211,11 @@ void BraveProfileWriter::SetWalletProperties(brave_rewards::RewardsService* pinned_item_count_++; sum_of_monthly_tips += amount_in_bat; - // Add `recurring` donation entry + // Add `recurring_donation` entry rewards_service->OnDonate(publisher.key, amount_in_bat, true); // Add publisher to `publisher_info` - // TODO: finish me + // TODO: finish me in https://github.com/brave/brave-core/pull/926 // ledger::PublisherInfo publisher_info; // publisher_info.id = publisher.key; // publisher_info.verified = publisher.verified; @@ -224,7 +224,7 @@ void BraveProfileWriter::SetWalletProperties(brave_rewards::RewardsService* // publisher_info.url = publisher.url; // publisher_info.provider = publisher.provider; // publisher_info.favicon_url = ""; - // publisher_info.month = ledger::PUBLISHER_MONTH::ANY; + // publisher_info.month = -1; // ledger::PUBLISHER_MONTH::ANY; // rewards_service->SavePublisherInfo(publisher_info); } } @@ -248,7 +248,6 @@ void BraveProfileWriter::SetWalletProperties(brave_rewards::RewardsService* new_contribution_amount_ = minimum_monthly_contribution; } } - rewards_service->SetUserChangedContribution(); rewards_service->SetContributionAmount(new_contribution_amount_); rewards_service->SetAutoContribute(auto_contribute_enabled); } diff --git a/components/brave_rewards/browser/rewards_service.cc b/components/brave_rewards/browser/rewards_service.cc index 2ef124d74e75..ef2e0f0ace80 100644 --- a/components/brave_rewards/browser/rewards_service.cc +++ b/components/brave_rewards/browser/rewards_service.cc @@ -35,7 +35,6 @@ void RewardsService::AddObserver(RewardsServiceObserver* observer) { } void RewardsService::RemoveObserver(RewardsServiceObserver* observer) { - LOG(INFO) << "RewardsService::RemoveObserver: " << observer; observers_.RemoveObserver(observer); } diff --git a/components/brave_rewards/browser/rewards_service_impl.cc b/components/brave_rewards/browser/rewards_service_impl.cc index 5bf9d2d612da..e97a89724e0e 100644 --- a/components/brave_rewards/browser/rewards_service_impl.cc +++ b/components/brave_rewards/browser/rewards_service_impl.cc @@ -1073,9 +1073,13 @@ void RewardsServiceImpl::SetPublisherAllowVideos(bool allow) const { } void RewardsServiceImpl::SetContributionAmount(double amount) const { + ledger_->SetUserChangedContribution(); ledger_->SetContributionAmount(amount); } +// TODO: remove me (and pure virtual definition) +// see https://github.com/brave/brave-core/commit/c4ef62c954a64fca18ae83ff8ffd611137323420#diff-aa3505dbf36b5d03d8ba0751e0c99904R385 +// and https://github.com/brave-intl/bat-native-ledger/commit/27f3ceb471d61c84052737ff201fe18cb9a6af32#diff-e303122e010480b2226895b9470891a3R135 void RewardsServiceImpl::SetUserChangedContribution() const { ledger_->SetUserChangedContribution(); }