d-pollard / Pokemon-GO-node-api

Pokemon Go! Node API library
MIT License
16 stars 4 forks source link

Random -> TypeError: Cannot read property 'username' of null #6

Closed FabioAntunes closed 8 years ago

FabioAntunes commented 8 years ago

Sometimes I'm getting this:

[i] Received Google access token! {Expires: 1469838239}
[i] Received API Endpoint: https://pgorelease.nianticlabs.com/plfe/553/rpc
TypeError: Cannot read property 'username' of null
    at api_req.then (/home/fabio/playground/pokemon-go-map/node_modules/pokemon-go-node-api/pokego.js:260:16)
    at process._tickCallback (internal/process/next_tick.js:103:7)
d-pollard commented 8 years ago

And the username is set?

FabioAntunes commented 8 years ago

Yep if I kill the server and start it again it works, it's doing this randomly.

d-pollard commented 8 years ago

Ill for sure take a look at it