New issue
Advanced search Search tips

Issue 852562 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Sep 25
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Chrome , Mac
Pri: 3
Type: Bug



Sign in to add a comment

Migrate local credit card save callback to BindOnce/OnceClosure

Project Member Reported by jsaul@google.com, Jun 13 2018

Issue description

During https://chromium-review.googlesource.com/c/chromium/src/+/1083880, we had to split SaveCardCallback between local and upload versions due to adding a parameter to the upload version.  It resulted in the following presubmit error:

** Presubmit Warnings **
Banned functions were used.
    chrome/browser/autofill/autofill_save_card_infobar_delegate_mobile_unittest.cc:129:
      Please consider using base::{Once,Repeating}Closure instead
      of base::Closure. (crbug.com/714018)
    chrome/browser/ui/autofill/chrome_autofill_client.cc:216:
      Please consider using base::{Once,Repeating}Closure instead
      of base::Closure. (crbug.com/714018)
    chrome/browser/ui/autofill/save_card_bubble_controller_impl.h:115:
      Please consider using base::{Once,Repeating}Closure instead
      of base::Closure. (crbug.com/714018)
    chrome/browser/ui/autofill/save_card_bubble_controller_impl_unittest.cc:99:
      Please consider using base::Bind{Once,Repeating} instead
      of base::Bind. (crbug.com/714018)
    components/autofill/core/browser/autofill_save_card_infobar_delegate_mobile.cc:34:
      Please consider using base::{Once,Repeating}Closure instead
      of base::Closure. (crbug.com/714018)
    components/autofill/core/browser/autofill_save_card_infobar_delegate_mobile.h:36:
      Please consider using base::{Once,Repeating}Closure instead
      of base::Closure. (crbug.com/714018)
    components/autofill/core/browser/autofill_save_card_infobar_delegate_mobile.h:82:
      Please consider using base::{Once,Repeating}Closure instead
      of base::Closure. (crbug.com/714018)
    ios/chrome/browser/ui/autofill/chrome_autofill_client_ios.mm:168:
      Please consider using base::{Once,Repeating}Closure instead
      of base::Closure. (crbug.com/714018)

These should probably be changed to BindOnce/OnceClosure, but note that web_view_autofill_client_ios.mm actually lists it as a RepeatingClosure (https://cs.chromium.org/chromium/src/ios/web_view/internal/autofill/web_view_autofill_client_ios.mm?l=87&rcl=7bcf3f69b49e8f441e2c0ee94b04ba2c694319dd).
 

Comment 1 by jsaul@google.com, Jun 14 2018

Description: Show this description
Project Member

Comment 2 by bugdroid1@chromium.org, Sep 25

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/774ccfd00ac49d2eb8d6701f8338c01e437c5806

commit 774ccfd00ac49d2eb8d6701f8338c01e437c5806
Author: Jared Saul <jsaul@google.com>
Date: Tue Sep 25 21:24:48 2018

[Autofill] Use OnceClosure/Callback for credit card save and risk fingerprinting

This also blocks presubmits on CL 1236291, so I'm resolving it separately beforehand.

Tested that local and upload credit card save still both work correctly on Linux.

Bug:  852562 
Cq-Include-Trybots: luci.chromium.try:ios-simulator-cronet;luci.chromium.try:ios-simulator-full-configs
Change-Id: I6a01f8215e235c3d4bb265a0f471d653cb02c517
Reviewed-on: https://chromium-review.googlesource.com/1237615
Reviewed-by: John Wu <jzw@chromium.org>
Reviewed-by: Moe Ahmadi <mahmadi@chromium.org>
Reviewed-by: Richard Coles <torne@chromium.org>
Reviewed-by: Rouslan Solomakhin <rouslan@chromium.org>
Reviewed-by: Fabio Tirelo <ftirelo@chromium.org>
Reviewed-by: Sebastien Seguin-Gagnon <sebsg@chromium.org>
Commit-Queue: Jared Saul <jsaul@google.com>
Cr-Commit-Position: refs/heads/master@{#594108}
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/android_webview/browser/aw_autofill_client.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/android_webview/browser/aw_autofill_client.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/chrome/browser/autofill/risk_util.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/chrome/browser/autofill/risk_util.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/chrome/browser/ui/autofill/chrome_autofill_client.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/chrome/browser/ui/autofill/chrome_autofill_client.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/chrome/browser/ui/autofill/save_card_bubble_controller_impl.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/chrome/browser/ui/autofill/save_card_bubble_controller_impl.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/chrome/browser/ui/autofill/save_card_bubble_controller_impl_unittest.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/chrome/browser/ui/views/payments/cvc_unmask_view_controller.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/chrome/browser/ui/views/payments/cvc_unmask_view_controller.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/components/autofill/content/browser/risk/fingerprint.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/components/autofill/content/browser/risk/fingerprint.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/components/autofill/content/browser/risk/fingerprint_browsertest.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/components/autofill/core/browser/autofill_client.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/components/autofill/core/browser/autofill_save_card_infobar_delegate_mobile.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/components/autofill/core/browser/autofill_save_card_infobar_delegate_mobile.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/components/autofill/core/browser/credit_card_save_manager.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/components/autofill/core/browser/credit_card_save_manager_unittest.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/components/autofill/core/browser/risk_data_loader.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/components/autofill/core/browser/test_autofill_client.cc
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/components/autofill/core/browser/test_autofill_client.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/ios/chrome/browser/ui/autofill/chrome_autofill_client_ios.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/ios/chrome/browser/ui/autofill/chrome_autofill_client_ios.mm
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/ios/web_view/internal/autofill/cwv_autofill_client_ios_bridge.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/ios/web_view/internal/autofill/cwv_autofill_controller.mm
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/ios/web_view/internal/autofill/web_view_autofill_client_ios.h
[modify] https://crrev.com/774ccfd00ac49d2eb8d6701f8338c01e437c5806/ios/web_view/internal/autofill/web_view_autofill_client_ios.mm

Status: Fixed (was: Assigned)

Sign in to add a comment