Chromium Code Reviews| Index: chrome/browser/android/webapk/webapk_update_manager.cc |
| diff --git a/chrome/browser/android/webapk/webapk_update_manager.cc b/chrome/browser/android/webapk/webapk_update_manager.cc |
| index 235dab3f0e8b2eb842b52493e64f3fb4ae8bcd84..7c690c739a01c0ceffb9a3a2ff0be6ff6b872399 100644 |
| --- a/chrome/browser/android/webapk/webapk_update_manager.cc |
| +++ b/chrome/browser/android/webapk/webapk_update_manager.cc |
| @@ -29,10 +29,11 @@ bool WebApkUpdateManager::Register(JNIEnv* env) { |
| // static |
| void WebApkUpdateManager::OnBuiltWebApk(const std::string& id, |
| - bool success, |
| + WebApkInstallResult result, |
| const std::string& webapk_package) { |
| JNIEnv* env = base::android::AttachCurrentThread(); |
| + bool success = (result == WebApkInstallResult::INSTALLED); |
|
dominickn
2017/03/05 23:52:40
Can we get rid of the logging here now?
That make
pkotwicz
2017/03/12 21:11:48
Done.
|
| if (success) { |
| DVLOG(1) |
| << "Sent request to update WebAPK to server. Seems to have worked."; |
| @@ -115,8 +116,8 @@ static void UpdateAsync( |
| WebApkInstallService* install_service = WebApkInstallService::Get(profile); |
| if (install_service->IsInstallInProgress(info.manifest_url)) { |
| base::ThreadTaskRunnerHandle::Get()->PostTask( |
| - FROM_HERE, |
| - base::Bind(&WebApkUpdateManager::OnBuiltWebApk, id, false, "")); |
| + FROM_HERE, base::Bind(&WebApkUpdateManager::OnBuiltWebApk, id, |
| + WebApkInstallResult::INSTALL_FAILED, "")); |
|
dominickn
2017/03/05 23:52:40
Is it worth having a separate result case here to
pkotwicz
2017/03/12 21:11:48
I don't think so. An update being already in progr
|
| return; |
| } |
| install_service->UpdateAsync( |