diff --git a/lib/plugins/leetcode.js b/lib/plugins/leetcode.js index e1da31e6..cc540ada 100644 --- a/lib/plugins/leetcode.js +++ b/lib/plugins/leetcode.js @@ -264,7 +264,11 @@ function formatResult(result) { x.expected_answer = result.expected_output; x.stdout = result.std_output; } else { - x.stdout = util.inspect((result.code_output || []).join('\n')); + let output = result.code_output || []; + if (Array.isArray(output)) { + output = output.join('\n'); + } + x.stdout = util.inspect(output); } // make sure we pass eveything! diff --git a/package-lock.json b/package-lock.json index a6257580..3b484076 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "vsc-leetcode-cli", - "version": "2.6.9", + "version": "2.6.10", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index cd18c186..d26bb49c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vsc-leetcode-cli", - "version": "2.6.9", + "version": "2.6.10", "description": "A cli tool to enjoy leetcode!", "preferGlobal": "true", "engines": { pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy