| Index: components/autofill/core/browser/credit_card.cc
|
| diff --git a/components/autofill/core/browser/credit_card.cc b/components/autofill/core/browser/credit_card.cc
|
| index b4c1c9eb2ccc4fd56c4fd559c7d8982198e033b0..dd26e5ebc575179fc9dc2d1af8a65f3ebfb31efb 100644
|
| --- a/components/autofill/core/browser/credit_card.cc
|
| +++ b/components/autofill/core/browser/credit_card.cc
|
| @@ -102,9 +102,10 @@ CreditCard::CreditCard(RecordType type, const std::string& server_id)
|
| type_(kGenericCard),
|
| expiration_month_(0),
|
| expiration_year_(0),
|
| - server_id_(server_id),
|
| server_status_(OK) {
|
| DCHECK(type == MASKED_SERVER_CARD || type == FULL_SERVER_CARD);
|
| + DCHECK(!server_id.empty());
|
| + set_server_id(server_id);
|
| }
|
|
|
| CreditCard::CreditCard()
|
| @@ -502,6 +503,7 @@ base::string16 CreditCard::TypeAndLastFourDigits() const {
|
| }
|
|
|
| void CreditCard::operator=(const CreditCard& credit_card) {
|
| + set_server_id(credit_card.server_id());
|
| set_use_count(credit_card.use_count());
|
| set_use_date(credit_card.use_date());
|
| set_modification_date(credit_card.modification_date());
|
| @@ -515,7 +517,6 @@ void CreditCard::operator=(const CreditCard& credit_card) {
|
| type_ = credit_card.type_;
|
| expiration_month_ = credit_card.expiration_month_;
|
| expiration_year_ = credit_card.expiration_year_;
|
| - server_id_ = credit_card.server_id_;
|
| server_status_ = credit_card.server_status_;
|
|
|
| set_guid(credit_card.guid());
|
| @@ -567,7 +568,7 @@ int CreditCard::Compare(const CreditCard& credit_card) const {
|
| return comparison;
|
| }
|
|
|
| - int comparison = server_id_.compare(credit_card.server_id_);
|
| + int comparison = server_id().compare(credit_card.server_id());
|
| if (comparison != 0)
|
| return comparison;
|
|
|
|
|