From 251e63ae03e6c6f7d2afa6ab5af44216ed9004db Mon Sep 17 00:00:00 2001 From: James M Snell Date: Fri, 29 Nov 2024 08:24:11 -0800 Subject: [PATCH] net: add net.BlockList.isBlockList(value) PR-URL: https://github.com/nodejs/node/pull/56078 Reviewed-By: Yagiz Nizipli Reviewed-By: theanarkh Reviewed-By: Luigi Pinca Reviewed-By: Matteo Collina Reviewed-By: Chemi Atlow --- doc/api/net.md | 9 +++++++++ lib/internal/blocklist.js | 9 +++++++++ test/parallel/test-blocklist.js | 5 +++++ 3 files changed, 23 insertions(+) diff --git a/doc/api/net.md b/doc/api/net.md index 513c405d80e66d..770398a7ef2bb5 100644 --- a/doc/api/net.md +++ b/doc/api/net.md @@ -170,6 +170,15 @@ added: The list of rules added to the blocklist. +### `BlockList.isBlockList(value)` + + + +* `value` {any} Any JS value +* Returns `true` if the `value` is a `net.BlockList`. + ## Class: `net.SocketAddress`