JWT Decode is not working
I've tried everything I could
let user_id = jwt.decode(req.body.auth_token).id;
req.body.auth_token is not null, it's returning the token!
It's working, I was passing token between ""
Same issue as in #587
I was also receiving a null value when trying to use jwt.decode(token). Turns out I also needed to parse it jwt.decode(JSON.parse(token))
Most helpful comment
I was also receiving a null value when trying to use
jwt.decode(token). Turns out I also needed to parse itjwt.decode(JSON.parse(token))