node-facebook-client icon indicating copy to clipboard operation
node-facebook-client copied to clipboard

html returned sometimes which causes stacktrace

Open lookfirst opened this issue 13 years ago • 0 comments

Every once and a while FB probably messes up and starts to return junk which causes a stack trace...

2012-12-22 00:59:51+00:00 app web.3     - - undefined:1
2012-12-22 00:59:51+00:00 app web.3     - - <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2012-12-22 00:59:51+00:00 app web.3     - - ^
2012-12-22 00:59:51+00:00 app web.3     - - SyntaxError: Unexpected token <
    at Object.parse [as parser] (native)
    at IncomingMessage.<anonymous> (/app/node_modules/facebook-client/lib/facebook-client/FacebookClient.js:70:28)
    at IncomingMessage.EventEmitter.emit (events.js:126:20)
    at IncomingMessage._emitEnd (http.js:366:10)
    at HTTPParser.parserOnMessageComplete [as onMessageComplete] (http.js:149:23)
    at CleartextStream.socketOnData [as ondata] (http.js:1367:20)
    at CleartextStream.CryptoStream._push (tls.js:526:27)
    at SecurePair.cycle (tls.js:880:20)
    at EncryptedStream.CryptoStream.write (tls.js:267:13)
    at Socket.ondata (stream.js:38:26) EXCEPT

lookfirst avatar Dec 22 '12 22:12 lookfirst