summaryrefslogtreecommitdiffstats
path: root/chrome/browser/extensions/api/sockets_tcp/sockets_tcp_api.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/extensions/api/sockets_tcp/sockets_tcp_api.cc')
-rw-r--r--chrome/browser/extensions/api/sockets_tcp/sockets_tcp_api.cc5
1 files changed, 2 insertions, 3 deletions
diff --git a/chrome/browser/extensions/api/sockets_tcp/sockets_tcp_api.cc b/chrome/browser/extensions/api/sockets_tcp/sockets_tcp_api.cc
index 2d1dd17..9fdff0f 100644
--- a/chrome/browser/extensions/api/sockets_tcp/sockets_tcp_api.cc
+++ b/chrome/browser/extensions/api/sockets_tcp/sockets_tcp_api.cc
@@ -6,7 +6,6 @@
#include "chrome/browser/extensions/api/socket/tcp_socket.h"
#include "chrome/browser/extensions/api/sockets_tcp/tcp_socket_event_dispatcher.h"
-#include "chrome/browser/profiles/profile.h"
#include "chrome/common/extensions/api/sockets/sockets_manifest_data.h"
#include "content/public/common/socket_permission_request.h"
#include "net/base/net_errors.h"
@@ -159,7 +158,7 @@ bool SocketsTcpSetPausedFunction::Prepare() {
params_ = api::sockets_tcp::SetPaused::Params::Create(*args_);
EXTENSION_FUNCTION_VALIDATE(params_.get());
- socket_event_dispatcher_ = TCPSocketEventDispatcher::Get(GetProfile());
+ socket_event_dispatcher_ = TCPSocketEventDispatcher::Get(browser_context());
DCHECK(socket_event_dispatcher_) << "There is no socket event dispatcher. "
"If this assertion is failing during a test, then it is likely that "
"TestExtensionSystem is failing to provide an instance of "
@@ -244,7 +243,7 @@ bool SocketsTcpConnectFunction::Prepare() {
params_ = sockets_tcp::Connect::Params::Create(*args_);
EXTENSION_FUNCTION_VALIDATE(params_.get());
- socket_event_dispatcher_ = TCPSocketEventDispatcher::Get(GetProfile());
+ socket_event_dispatcher_ = TCPSocketEventDispatcher::Get(browser_context());
DCHECK(socket_event_dispatcher_) << "There is no socket event dispatcher. "
"If this assertion is failing during a test, then it is likely that "
"TestExtensionSystem is failing to provide an instance of "