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

Unified Diff: chrome/browser/extensions/api/sockets_tcp_server/sockets_tcp_server_api.cc

Issue 177003015: Pull AsyncApiFunction out of src/chrome (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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
Index: chrome/browser/extensions/api/sockets_tcp_server/sockets_tcp_server_api.cc
diff --git a/chrome/browser/extensions/api/sockets_tcp_server/sockets_tcp_server_api.cc b/chrome/browser/extensions/api/sockets_tcp_server/sockets_tcp_server_api.cc
index 23dc3aa70f4b5a8fbd780317688d8d42404f6d69..eff4cb5bb7007a823565136cc68ca8bb8bfb2ce6 100644
--- a/chrome/browser/extensions/api/sockets_tcp_server/sockets_tcp_server_api.cc
+++ b/chrome/browser/extensions/api/sockets_tcp_server/sockets_tcp_server_api.cc
@@ -129,7 +129,7 @@ bool SocketsTcpServerSetPausedFunction::Prepare() {
params_ = api::sockets_tcp_server::SetPaused::Params::Create(*args_);
EXTENSION_FUNCTION_VALIDATE(params_.get());
- socket_event_dispatcher_ = TCPServerSocketEventDispatcher::Get(GetProfile());
+ socket_event_dispatcher_ = TCPServerSocketEventDispatcher::Get(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 "
@@ -164,7 +164,7 @@ bool SocketsTcpServerListenFunction::Prepare() {
params_ = api::sockets_tcp_server::Listen::Params::Create(*args_);
EXTENSION_FUNCTION_VALIDATE(params_.get());
- socket_event_dispatcher_ = TCPServerSocketEventDispatcher::Get(GetProfile());
+ socket_event_dispatcher_ = TCPServerSocketEventDispatcher::Get(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 "

Powered by Google App Engine
This is Rietveld 408576698