Uh oh!
There was an error while loading. Please reload this page.
events: EventTarget use validators and small fix - #33663
Conversation
There was a problem hiding this comment.
I'd assume this was a bug (dept instead of depth) but wanted to point out since I'm not sure how this interaction works (inspecting circular events I assume?).
Also, use NumberIsInteger instead of just null check.
There was a problem hiding this comment.
That is both correct. The user should only ever pass through null or and integer but it would be possible to pass through other types as well.
There was a problem hiding this comment.
| Object, | |
| NumberIsInteger, | |
| NumberIsInteger, | |
| Object, |
benjamingr
commented
May 31, 2020
Generally LGTM - can you add a test? |
lundibundi
commented
May 31, 2020
Do you mean test for |
02a268e to
c434ce6CompareThere was a problem hiding this comment.
Also, @BridgeAR shouldn't this return this? (as well as the other one)
There was a problem hiding this comment.
Yes, that would be ideal. this will just let inspect() to properly know what to do.
benjamingr
commented
May 31, 2020
Yes. cc @jasnell wdyt? If this isn't too much work to test I think we should add a test - but if it's a lot of work I am fine with LGTMing without one. |
8ae28ff to
2935f72Comparelundibundi
commented
May 31, 2020
There was a problem hiding this comment.
Yes, that would be ideal. this will just let inspect() to properly know what to do.
There was a problem hiding this comment.
That is both correct. The user should only ever pass through null or and integer but it would be possible to pass through other types as well.
c434ce6 to
9a50794CompareBridgeAR
commented
May 31, 2020
@lundibundi I rebased your branch and everything should be in order again. The tests pass locally. Please have a look to verify that, thanks. |
lundibundi
commented
May 31, 2020
@BridgeAR thanks :). |
nodejs-github-bot
commented
May 31, 2020
jasnell
commented
Jun 17, 2020
This needs another rebase, unfortunately. |
9a50794 to
8713e07Comparenodejs-github-bot
commented
Jun 19, 2020
jasnell
commented
Jun 22, 2020
Closing in favor of #34015 (which combines this and other |
Checklist
make -j4 test(UNIX), orvcbuild test(Windows) passes/cc @jasnell @nodejs/events