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

Side by Side Diff: lib/filterClasses.js

Issue 29799602: Noissue - Avoid setting BlockingFilter instance properties (Closed) Base URL: https://hg.adblockplus.org/adblockpluscore/
Patch Set: Created June 5, 2018, 2:13 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * This file is part of Adblock Plus <https://adblockplus.org/>, 2 * This file is part of Adblock Plus <https://adblockplus.org/>,
3 * Copyright (C) 2006-present eyeo GmbH 3 * Copyright (C) 2006-present eyeo GmbH
4 * 4 *
5 * Adblock Plus is free software: you can redistribute it and/or modify 5 * Adblock Plus is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as 6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
8 * 8 *
9 * Adblock Plus is distributed in the hope that it will be useful, 9 * Adblock Plus is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 888 matching lines...) Expand 10 before | Expand all | Expand 10 after
899 * BlockingFilter.prototype.rewrite. 899 * BlockingFilter.prototype.rewrite.
900 * @constructor 900 * @constructor
901 * @augments RegExpFilter 901 * @augments RegExpFilter
902 */ 902 */
903 function BlockingFilter(text, regexpSource, contentType, matchCase, domains, 903 function BlockingFilter(text, regexpSource, contentType, matchCase, domains,
904 thirdParty, sitekeys, collapse, csp, rewrite) 904 thirdParty, sitekeys, collapse, csp, rewrite)
905 { 905 {
906 RegExpFilter.call(this, text, regexpSource, contentType, matchCase, domains, 906 RegExpFilter.call(this, text, regexpSource, contentType, matchCase, domains,
907 thirdParty, sitekeys); 907 thirdParty, sitekeys);
908 908
909 this.collapse = collapse; 909 if (collapse != null)
910 this.collapse = collapse;
911
910 this.csp = csp; 912 this.csp = csp;
911 this.rewrite = rewrite; 913 this.rewrite = rewrite;
912 } 914 }
913 exports.BlockingFilter = BlockingFilter; 915 exports.BlockingFilter = BlockingFilter;
914 916
915 BlockingFilter.prototype = extend(RegExpFilter, { 917 BlockingFilter.prototype = extend(RegExpFilter, {
916 type: "blocking", 918 type: "blocking",
917 919
918 /** 920 /**
919 * Defines whether the filter should collapse blocked content. 921 * Defines whether the filter should collapse blocked content.
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
1094 */ 1096 */
1095 function ElemHideEmulationFilter(text, domains, selector) 1097 function ElemHideEmulationFilter(text, domains, selector)
1096 { 1098 {
1097 ElemHideBase.call(this, text, domains, selector); 1099 ElemHideBase.call(this, text, domains, selector);
1098 } 1100 }
1099 exports.ElemHideEmulationFilter = ElemHideEmulationFilter; 1101 exports.ElemHideEmulationFilter = ElemHideEmulationFilter;
1100 1102
1101 ElemHideEmulationFilter.prototype = extend(ElemHideBase, { 1103 ElemHideEmulationFilter.prototype = extend(ElemHideBase, {
1102 type: "elemhideemulation" 1104 type: "elemhideemulation"
1103 }); 1105 });
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld