From 2511a2ac5b46840af02b54dfe349a4a681fc21ed Mon Sep 17 00:00:00 2001 From: "Namhyeon, Go" Date: Sun, 20 Jun 2021 06:11:44 +0900 Subject: [PATCH] Update chrome.js --- lib/chrome.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/chrome.js b/lib/chrome.js index 654c5d4..16bb024 100644 --- a/lib/chrome.js +++ b/lib/chrome.js @@ -66,7 +66,7 @@ var ChromeObject = function() { }; this.setDebuggingPort = function(n) { - this.debuggingPort = n; + this.debuggingPort = (typeof(n) !== "number" ? this.debuggingPort : n); } this.createShoutcut = function(url) { @@ -161,7 +161,7 @@ var ChromeObject = function() { if (this.inPrivate) { cmd.push("--incognito"); } - + if (this.debuggingPort > 0) { cmd.push("--remote-debugging-port=" + this.debuggingPort); }