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

Unified Diff: chrome/browser/ui/webui/app_launcher_handler.cc

Issue 6602010: Added "--login-user=" option for the Guest session. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/chrome/browser/chromeos/login
Patch Set: merge Created 9 years, 10 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
« no previous file with comments | « chrome/browser/ui/views/bookmark_bar_view.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/app_launcher_handler.cc
diff --git a/chrome/browser/ui/webui/app_launcher_handler.cc b/chrome/browser/ui/webui/app_launcher_handler.cc
index 3b23bff24d83dccacc77338a488e119a51e78b2a..ddde4387473f2dea55c98a6c49bc404c6eaa9370 100644
--- a/chrome/browser/ui/webui/app_launcher_handler.cc
+++ b/chrome/browser/ui/webui/app_launcher_handler.cc
@@ -132,8 +132,10 @@ bool AppLauncherHandler::HandlePing(Profile* profile, const std::string& path) {
// At this point, the user must have used the app launcher, so we hide the
// promo if its still displayed.
- if (is_promo_active)
+ if (is_promo_active) {
+ DCHECK(profile->GetExtensionService());
profile->GetExtensionService()->default_apps()->SetPromoHidden();
+ }
if (is_web_store_ping) {
RecordWebStoreLaunch(is_promo_active);
@@ -477,10 +479,8 @@ void AppLauncherHandler::RecordAppLaunchByURL(
CHECK(bucket != extension_misc::APP_LAUNCH_BUCKET_INVALID);
GURL url(UnescapeURLComponent(escaped_url, kUnescapeRules));
- // TODO: the ExtensionService should never be NULL, but in some cases it is,
- // see bug 73768. After it is resolved, the explicit test can go away.
- ExtensionService* service = profile->GetExtensionService();
- if (!service || !service->IsInstalledApp(url))
+ DCHECK(profile->GetExtensionService());
+ if (!profile->GetExtensionService()->IsInstalledApp(url))
return;
UMA_HISTOGRAM_ENUMERATION(extension_misc::kAppLaunchHistogram, bucket,
« no previous file with comments | « chrome/browser/ui/views/bookmark_bar_view.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698