From 392978d95f387cc0a4c885d007e2b05366410f3c Mon Sep 17 00:00:00 2001 From: Tobias Speicher Date: Tue, 5 Apr 2022 06:25:53 +0200 Subject: [PATCH] fix: replace deprecated String.prototype.substr() .substr() is deprecated so we replace it with .slice() which works similarily but isn't deprecated Signed-off-by: Tobias Speicher --- bin/node-which | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/node-which b/bin/node-which index 7cee372..89c161c 100755 --- a/bin/node-which +++ b/bin/node-which @@ -20,7 +20,7 @@ var args = process.argv.slice(2).filter(function (arg) { return false } - var flags = arg.substr(1).split('') + var flags = arg.slice(1).split('') for (var f = 0; f < flags.length; f++) { var flag = flags[f] switch (flag) {