Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6157)

Unified Diff: chrome/browser/extensions/api/webstore_private/webstore_private_api.cc

Issue 481433005: Extensions: Move id_util functions to crx_file component. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: revert last patchset. function returns Extension* and can't use an assert. Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/api/webstore_private/webstore_private_api.cc
diff --git a/chrome/browser/extensions/api/webstore_private/webstore_private_api.cc b/chrome/browser/extensions/api/webstore_private/webstore_private_api.cc
index addd6cacb6d882ed559f31efbdbf83c664e8c7b8..66915fe64be7e44c268fc47a218a7d48e4b1c261 100644
--- a/chrome/browser/extensions/api/webstore_private/webstore_private_api.cc
+++ b/chrome/browser/extensions/api/webstore_private/webstore_private_api.cc
@@ -36,6 +36,7 @@
#include "chrome/browser/ui/browser.h"
#include "chrome/common/extensions/extension_constants.h"
#include "chrome/common/pref_names.h"
+#include "components/crx_file/id_util.h"
#include "components/signin/core/browser/signin_manager.h"
#include "components/signin/core/common/profile_management_switches.h"
#include "content/public/browser/gpu_data_manager.h"
@@ -237,7 +238,7 @@ bool WebstorePrivateBeginInstallWithManifest3Function::RunAsync() {
params_ = BeginInstallWithManifest3::Params::Create(*args_);
EXTENSION_FUNCTION_VALIDATE(params_);
- if (!extensions::Extension::IdIsValid(params_->details.id)) {
+ if (!crx_file::id_util::IdIsValid(params_->details.id)) {
SetResultCode(INVALID_ID);
error_ = kInvalidIdError;
return false;
@@ -508,7 +509,7 @@ bool WebstorePrivateCompleteInstallFunction::RunAsync() {
scoped_ptr<CompleteInstall::Params> params(
CompleteInstall::Params::Create(*args_));
EXTENSION_FUNCTION_VALIDATE(params);
- if (!extensions::Extension::IdIsValid(params->expected_id)) {
+ if (!crx_file::id_util::IdIsValid(params->expected_id)) {
error_ = kInvalidIdError;
return false;
}

Powered by Google App Engine
This is Rietveld 408576698