CookieStore::DeleteCookieAsync appears unused (outside a few tests), so remove it

https://chromium-review.googlesource.com/c/chromium/src/+/1456677
This commit is contained in:
deepak1556 2019-02-21 22:33:22 +05:30 committed by Samuel Attard
parent a7e2856bf0
commit ccd4a3c80c

View file

@ -175,9 +175,16 @@ void RemoveCookieOnIO(scoped_refptr<net::URLRequestContextGetter> getter,
const GURL& url, const GURL& url,
const std::string& name, const std::string& name,
util::Promise promise) { util::Promise promise) {
GetCookieStore(getter)->DeleteCookieAsync( net::CookieDeletionInfo cookie_info;
url, name, cookie_info.url = url;
base::BindOnce(util::Promise::ResolveEmptyPromise, std::move(promise))); cookie_info.name = name;
GetCookieStore(getter)->DeleteAllMatchingInfoAsync(
std::move(cookie_info),
base::BindOnce(
[](util::Promise promise, uint32_t num_deleted) {
util::Promise::ResolveEmptyPromise(std::move(promise));
},
std::move(promise)));
} }
// Callback of SetCookie. // Callback of SetCookie.