From a904e6c667adeed990f647e826041a76c4ce3caa Mon Sep 17 00:00:00 2001 From: amaitland Date: Thu, 16 Apr 2015 13:13:32 +1000 Subject: [PATCH] Simplify code by removing local variable handled variable - simply return --- CefSharp.Core/ResourceHandlerWrapper.cpp | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/CefSharp.Core/ResourceHandlerWrapper.cpp b/CefSharp.Core/ResourceHandlerWrapper.cpp index bff1815f0..820b4b419 100644 --- a/CefSharp.Core/ResourceHandlerWrapper.cpp +++ b/CefSharp.Core/ResourceHandlerWrapper.cpp @@ -17,19 +17,12 @@ namespace CefSharp { _callback = callback; - bool handled = false; - AutoLock lock_scope(_syncRoot); auto schemeResponse = gcnew SchemeHandlerResponse(this); - auto requestWrapper = gcnew CefRequestWrapper(request); - if (_handler->ProcessRequestAsync(requestWrapper, schemeResponse)) - { - handled = true; - } - return handled; + return _handler->ProcessRequestAsync(requestWrapper, schemeResponse); } void ResourceHandlerWrapper::ProcessRequestCallback(ISchemeHandlerResponse^ response)