Skip to content
This repository has been archived by the owner on Mar 6, 2019. It is now read-only.

Commit

Permalink
Improved error handling
Browse files Browse the repository at this point in the history
  • Loading branch information
tmancey committed Jan 17, 2019
1 parent 9cef400 commit b180a1c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 0 additions & 2 deletions src/ads_impl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1019,8 +1019,6 @@ bool AdsImpl::IsSustainingAdInteraction() const {
}

bool AdsImpl::IsStillViewingAd() const {
std::string error_description;

UrlComponents last_shown_notification_info_url_components;
if (!ads_client_->GetUrlComponents(last_shown_notification_info_.url,
&last_shown_notification_info_url_components)) {
Expand Down
4 changes: 2 additions & 2 deletions src/bat/ads/issuers_info.cc
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Result IssuersInfo::FromJson(

// Public key
if (!document.HasMember("public_key")) {
if (error_description != nullptr) {
if (error_description) {
*error_description = "Catalog issuers public key is missing";
}

Expand All @@ -51,7 +51,7 @@ Result IssuersInfo::FromJson(

// Issuers
if (!document.HasMember("issuers")) {
if (error_description != nullptr) {
if (error_description) {
*error_description = "No catalog issuers";
}

Expand Down

0 comments on commit b180a1c

Please sign in to comment.