Closed
Description
Installed fine, but running the example given:
$ leetcode show 1 --solution
undefined:1
<!DOCTYPE html>
^
SyntaxError: Unexpected token < in JSON at position 0
at JSON.parse (<anonymous>)
at Request._callback (/usr/local/lib/node_modules/leetcode-cli/lib/plugins/solution.discuss.js:54:21)
at Request.self.callback (/usr/local/lib/node_modules/leetcode-cli/node_modules/request/request.js:186:22)
at Request.emit (events.js:180:13)
at Request.<anonymous> (/usr/local/lib/node_modules/leetcode-cli/node_modules/request/request.js:1163:10)
at Request.emit (events.js:180:13)
at IncomingMessage.<anonymous> (/usr/local/lib/node_modules/leetcode-cli/node_modules/request/request.js:1085:12)
at Object.onceWrapper (events.js:272:13)
at IncomingMessage.emit (events.js:185:15)
at endReadableNT (_stream_readable.js:1101:12)
Seems like it's an error in parse and it doesn't like the doctype.