0

Ok, so I stopped coding for a while and now im trying to get back into the flow of things as I've forgotten again.

Json code:

"{\"Statistics\":{\"76561198047386802\":{\"LastUpdate\":1557255652}}}"

jscode:

const obj = JSON.parse(jsonData)
  const object = obj.Statistics.76561198047386802;
  console.log(object.LastUpdate);

I am trying to pass this code through to get the lastupdate value. I keep trying to use the numbers above but getting errors on the output. Can you please show me my idiotic mistake lol.

Doug
  • 23
  • 1
  • 5

1 Answers1

0

You can try:

...
const object = obj.Statistics['76561198047386802'];
...
Ryan Nghiem
  • 2,417
  • 2
  • 18
  • 28