Index: chrome/browser/extensions/api/sockets_tcp/tcp_socket_event_dispatcher.cc |
diff --git a/chrome/browser/extensions/api/sockets_tcp/tcp_socket_event_dispatcher.cc b/chrome/browser/extensions/api/sockets_tcp/tcp_socket_event_dispatcher.cc |
index b0cf650c068884203451c0e903f525f3ac5f83c0..07a6c19fcf21cbe8db33450f6487ba8c5e1c9a40 100644 |
--- a/chrome/browser/extensions/api/sockets_tcp/tcp_socket_event_dispatcher.cc |
+++ b/chrome/browser/extensions/api/sockets_tcp/tcp_socket_event_dispatcher.cc |
@@ -31,18 +31,20 @@ ProfileKeyedAPIFactory<TCPSocketEventDispatcher>* |
} |
// static |
-TCPSocketEventDispatcher* TCPSocketEventDispatcher::Get(Profile* profile) { |
+TCPSocketEventDispatcher* TCPSocketEventDispatcher::Get( |
+ content::BrowserContext* context) { |
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
return ProfileKeyedAPIFactory<TCPSocketEventDispatcher>::GetForProfile( |
- profile); |
+ context); |
} |
-TCPSocketEventDispatcher::TCPSocketEventDispatcher(Profile* profile) |
+TCPSocketEventDispatcher::TCPSocketEventDispatcher( |
+ content::BrowserContext* context) |
: thread_id_(Socket::kThreadId), |
- profile_(profile) { |
+ profile_(Profile::FromBrowserContext(context)) { |
ApiResourceManager<ResumableTCPSocket>* manager = |
- ApiResourceManager<ResumableTCPSocket>::Get(profile); |
+ ApiResourceManager<ResumableTCPSocket>::Get(profile_); |
DCHECK(manager) << "There is no socket manager. " |
"If this assertion is failing during a test, then it is likely that " |
"TestExtensionSystem is failing to provide an instance of " |