From ec140d7160aeee29d2222051c3aaafa5f67af9bc Mon Sep 17 00:00:00 2001 From: Dmitry Semigradsky Date: Wed, 11 Nov 2020 18:52:57 +0300 Subject: [PATCH] doc: fix `events.getEventListeners` example PR-URL: https://github.com/nodejs/node/pull/36085 Reviewed-By: Luigi Pinca Reviewed-By: Benjamin Gruenbaum Reviewed-By: Yongsheng Zhang Reviewed-By: Antoine du Hamel --- doc/api/events.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/api/events.md b/doc/api/events.md index f74dac02945777..ef59450b974200 100644 --- a/doc/api/events.md +++ b/doc/api/events.md @@ -881,8 +881,8 @@ const { getEventListeners, EventEmitter } = require('events'); { const et = new EventTarget(); const listener = () => console.log('Events are fun'); - ee.addEventListener('foo', listener); - getEventListeners(ee, 'foo'); // [listener] + et.addEventListener('foo', listener); + getEventListeners(et, 'foo'); // [listener] } ```