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

Issue 29338279: Issue 3499 - Use new messaging API in the content policy implementation (Closed)

Created:
March 15, 2016, 10:57 a.m. by Wladimir Palant
Modified:
March 24, 2016, 2:53 p.m.
Reviewers:
Thomas Greiner, Erik
Visibility:
Public.

Description

Issue 3499 - Use new messaging API in the content policy implementation Repository: hg.adblockplus.org/adblockplus

Patch Set 1 #

Total comments: 6

Patch Set 2 : More obvious logic in postProcessNodes #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+49 lines, -52 lines) Patch
M lib/child/contentPolicy.js View 1 6 chunks +44 lines, -44 lines 2 comments Download
M lib/contentPolicy.js View 3 chunks +5 lines, -8 lines 0 comments Download

Messages

Total messages: 8
Wladimir Palant
March 15, 2016, 10:57 a.m. (2016-03-15 10:57:40 UTC) #1
Erik
https://codereview.adblockplus.org/29338279/diff/29338280/lib/child/contentPolicy.js File lib/child/contentPolicy.js (right): https://codereview.adblockplus.org/29338279/diff/29338280/lib/child/contentPolicy.js#newcode475 lib/child/contentPolicy.js:475: scheduledNodes = null; It appears that `postProcessNodes` is run ...
March 15, 2016, 8:57 p.m. (2016-03-15 20:57:42 UTC) #2
Erik
https://codereview.adblockplus.org/29338279/diff/29338280/lib/contentPolicy.js File lib/contentPolicy.js (right): https://codereview.adblockplus.org/29338279/diff/29338280/lib/contentPolicy.js#newcode91 lib/contentPolicy.js:91: port.on("shouldAllow", (message, sender) => this.shouldAllow(message)); `(message, sender) => this.shouldAllow(message)` ...
March 15, 2016, 10:57 p.m. (2016-03-15 22:57:00 UTC) #3
Wladimir Palant
https://codereview.adblockplus.org/29338279/diff/29338280/lib/child/contentPolicy.js File lib/child/contentPolicy.js (right): https://codereview.adblockplus.org/29338279/diff/29338280/lib/child/contentPolicy.js#newcode475 lib/child/contentPolicy.js:475: scheduledNodes = null; On 2016/03/15 20:57:41, Erik wrote: > ...
March 16, 2016, 10:13 a.m. (2016-03-16 10:13:00 UTC) #4
Thomas Greiner
https://codereview.adblockplus.org/29338279/diff/29338280/lib/contentPolicy.js File lib/contentPolicy.js (right): https://codereview.adblockplus.org/29338279/diff/29338280/lib/contentPolicy.js#newcode91 lib/contentPolicy.js:91: port.on("shouldAllow", (message, sender) => this.shouldAllow(message)); On 2016/03/16 10:13:00, Wladimir ...
March 16, 2016, 10:59 a.m. (2016-03-16 10:59:11 UTC) #5
Erik
On 2016/03/15 10:57:40, Wladimir Palant wrote: LGTM
March 16, 2016, 9:40 p.m. (2016-03-16 21:40:28 UTC) #6
Thomas Greiner
LGTM, merely a small suggestion https://codereview.adblockplus.org/29338279/diff/29338392/lib/child/contentPolicy.js File lib/child/contentPolicy.js (right): https://codereview.adblockplus.org/29338279/diff/29338392/lib/child/contentPolicy.js#newcode459 lib/child/contentPolicy.js:459: collapsedClass.then(cls => Detail: Anything ...
March 23, 2016, 6:47 p.m. (2016-03-23 18:47:59 UTC) #7
Wladimir Palant
March 24, 2016, 7:27 a.m. (2016-03-24 07:27:27 UTC) #8
https://codereview.adblockplus.org/29338279/diff/29338392/lib/child/contentPo...
File lib/child/contentPolicy.js (right):

https://codereview.adblockplus.org/29338279/diff/29338392/lib/child/contentPo...
lib/child/contentPolicy.js:459: collapsedClass.then(cls =>
On 2016/03/23 18:47:59, Thomas Greiner wrote:
> Detail: Anything wrong with calling it "collapsedClass" instead of "cls"?
> Because the promise is just a different representation of that same value.

They are not the same thing however. I would consider this highly confusing if
collapsedClass could refer to both the promise (variable outside the closure)
and actual value (parameter).

Powered by Google App Engine
This is Rietveld