From 6052ade038c585def4da9f09620c9e01addd525b Mon Sep 17 00:00:00 2001 From: NejcZdovc Date: Mon, 10 Aug 2020 10:34:23 +0200 Subject: [PATCH] Fixes claim for existing wallets Resolves https://github.com/brave/brave-browser/issues/11144 --- .../src/bat/ledger/internal/response/response_wallet.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/vendor/bat-native-ledger/src/bat/ledger/internal/response/response_wallet.cc b/vendor/bat-native-ledger/src/bat/ledger/internal/response/response_wallet.cc index 92cab7d0a92b..551aef5a3e7a 100644 --- a/vendor/bat-native-ledger/src/bat/ledger/internal/response/response_wallet.cc +++ b/vendor/bat-native-ledger/src/bat/ledger/internal/response/response_wallet.cc @@ -139,7 +139,8 @@ ledger::Result ParseRecoverWallet( // POST /v3/wallet/uphold/{payment_id}/claim // // Success: -// OK (201) +// CREATED (201) +// OK (200) // // Response Format: // {Empty body} @@ -175,7 +176,8 @@ ledger::Result CheckClaimWallet(const ledger::UrlResponse& response) { return ledger::Result::LEDGER_ERROR; } - if (response.status_code != net::HTTP_CREATED) { + if (response.status_code != net::HTTP_CREATED && + response.status_code != net::HTTP_OK) { return ledger::Result::LEDGER_ERROR; }