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

Unified Diff: base/scoped_observer.h

Issue 652183006: Revert of Listen to Off The Record profiles in ContentSettingsHandler. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkcr
Patch Set: Created 6 years, 2 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 | « no previous file | chrome/browser/ui/webui/options/content_settings_handler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/scoped_observer.h
diff --git a/base/scoped_observer.h b/base/scoped_observer.h
index 5b0d53353bab913125335acc0d925987c60b7dae..3754ed57e1d27c3b98f59b8c41262c7d80de9507 100644
--- a/base/scoped_observer.h
+++ b/base/scoped_observer.h
@@ -9,7 +9,6 @@
#include <vector>
#include "base/basictypes.h"
-#include "base/logging.h"
// ScopedObserver is used to keep track of the set of sources an object has
// attached itself to as an observer. When ScopedObserver is destroyed it
@@ -31,9 +30,7 @@
// Remove the object passed to the constructor as an observer from |source|.
void Remove(Source* source) {
- auto it = std::find(sources_.begin(), sources_.end(), source);
- DCHECK(it != sources_.end());
- sources_.erase(it);
+ sources_.erase(std::find(sources_.begin(), sources_.end(), source));
source->RemoveObserver(observer_);
}
« no previous file with comments | « no previous file | chrome/browser/ui/webui/options/content_settings_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698