Index: compiled/filter/WhitelistFilter.h |
=================================================================== |
--- a/compiled/filter/WhitelistFilter.h |
+++ b/compiled/filter/WhitelistFilter.h |
@@ -19,8 +19,17 @@ |
#include "RegExpFilter.h" |
class WhitelistFilter : public RegExpFilter |
{ |
public: |
explicit WhitelistFilter(const String& text, const RegExpFilterData& data); |
}; |
+ |
+template<> |
+inline WhitelistFilter* Filter::As<WhitelistFilter>() |
+{ |
+ if ((mType & Type::WHITELIST) == Type::WHITELIST) |
+ return nullptr; |
+ |
+ return static_cast<WhitelistFilter*>(this); |
+} |