Commit 96eb4c26 authored by Jonathan Freed's avatar Jonathan Freed Committed by Commit Bot

[Explore Sites] Forcing update of 'downloading' to 'current' on every

GetCatalogTask execution.

Bug: 908476
Change-Id: I5459d7fdfe8e5eaf2cd9c42e39c1606710cec838
Reviewed-on: https://chromium-review.googlesource.com/c/1355489
Commit-Queue: Jonathan Freed <freedjm@chromium.org>
Reviewed-by: default avatarJustin DeWitt <dewittj@chromium.org>
Cr-Commit-Position: refs/heads/master@{#612367}
parent cd44c42f
......@@ -58,9 +58,11 @@ void ExploreSitesServiceImpl::GetCatalog(CatalogCallback callback) {
if (!IsExploreSitesEnabled())
return;
// TODO(https://crbug.com/910255): Ensure the catalog swap doesn't happen
// during a session.
task_queue_.AddTask(std::make_unique<GetCatalogTask>(
explore_sites_store_.get(), check_for_new_catalog_, std::move(callback)));
check_for_new_catalog_ = false;
explore_sites_store_.get(), /*update_current*/ true,
std::move(callback)));
}
void ExploreSitesServiceImpl::GetCategoryImage(int category_id,
......
......@@ -92,11 +92,6 @@ class ExploreSitesServiceImpl : public ExploreSitesService,
int pixel_size,
EncodedImageList images);
// True when Chrome starts up, this is reset after the catalog is requested
// the first time in Chrome. This prevents the ESP from changing out from
// under a viewer.
bool check_for_new_catalog_ = true;
ImageHelper image_helper_;
// Used to control access to the ExploreSitesStore.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment