Godzil / Crunchy

Crunchy is capable of downloading anime episodes from the popular CrunchyRoll streaming service.
MIT License
95 stars 19 forks source link

Unexpected token u in JSON at position 0 #92

Closed ghost closed 6 years ago

ghost commented 6 years ago

Describe the bug Unexpected token u in JSON at position 0

Expected behavior Not to error out with the JSON

Error

 * INFO : Crunchy version 1.4.3
 * INFO : No locale set. Setting to the one reported by CR: "en"
 * INFO : You have a premium account! Good!
 * INFO : Checking availability for The Future Diary
undefined:1re Diary - s01e01 - Sign Up - [CrunchyRoll] : Fetching video...
undefined
^

SyntaxError: Unexpected token u in JSON at position 0
    at JSON.parse (<anonymous>)
    at Request._callback (C:\Users\Tom\AppData\Roaming\npm\node_modules\crunchy\dist\cli.js:11:26)
    at self.callback (C:\Users\Tom\AppData\Roaming\npm\node_modules\crunchy\node_modules\request\request.js:185:22)
    at emitOne (events.js:116:13)
    at Request.emit (events.js:211:7)
    at Request.onRequestError (C:\Users\Tom\AppData\Roaming\npm\node_modules\crunchy\node_modules\request\request.js:881:8)
    at emitOne (events.js:116:13)
    at ClientRequest.emit (events.js:211:7)
    at TLSSocket.socketErrorListener (_http_client.js:387:9)
    at emitOne (events.js:116:13)
    at TLSSocket.emit (events.js:211:7)
    at emitErrorNT (internal/streams/destroy.js:64:8)
    at _combinedTickCallback (internal/process/next_tick.js:138:11)
    at process._tickCallback (internal/process/next_tick.js:180:9)

Please fill theses informations: (Add a X between brackets to make them ticked if relevant)

Godzil commented 6 years ago

Well -o take a parameter. Are you sure to have put one?