Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: src/engine/Main.cpp

Issue 5115380229996544: Issue 1104 - Cannot uncheck Disable on website option in tool bar (Closed)
Patch Set: rename and rebase Created March 13, 2015, 4:48 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/plugin/AdblockPlusClient.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/engine/Main.cpp
diff --git a/src/engine/Main.cpp b/src/engine/Main.cpp
index 01ddcb6ca49a5ca2dc8dbc692d364abaae0ef70e..5930826552739e39188d440297e252135bcd9aa1 100644
--- a/src/engine/Main.cpp
+++ b/src/engine/Main.cpp
@@ -199,13 +199,18 @@ namespace
response << domains;
break;
}
- case Communication::PROC_IS_WHITELISTED_URL:
+ case Communication::PROC_GET_WHITELISTING_FITER:
{
std::string url;
request >> url;
AdblockPlus::FilterPtr match = filterEngine->Matches(url,
AdblockPlus::FilterEngine::ContentType::CONTENT_TYPE_DOCUMENT, url);
- response << (match && match->GetType() == AdblockPlus::Filter::TYPE_EXCEPTION);
+ std::string filterText;
+ if (match && match->GetType() == AdblockPlus::Filter::TYPE_EXCEPTION)
+ {
+ filterText = match->GetProperty("text")->AsString();
+ }
+ response << filterText;
break;
}
case Communication::PROC_IS_ELEMHIDE_WHITELISTED_ON_URL:
« no previous file with comments | « no previous file | src/plugin/AdblockPlusClient.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld