-4

Odd Chrome Behaviour

enter image description here

I'm experiencing a situation where console.log()'ing an array displays all the values correctly, but then expanding that array in chromes view gives completely different values.

See the picture for the behavior.

abhit
  • 973
  • 3
  • 17
  • 40
alawrence
  • 61
  • 1
  • 2
  • I feel like it's this problem: https://stackoverflow.com/questions/24175017/google-chrome-console-log-inconsistency-with-objects-and-arrays Does the array change after it's logged? – Dominic K Dec 15 '17 at 05:41
  • It was an object reference issue. I made a copy of the object I was parsing and it fixed the issue. I guess the values inside the array were actually just referencing to something that's changing elsewhere in my code. That was a doozy. – alawrence Dec 15 '17 at 06:01

1 Answers1

0

It was an object reference issue. I made a copy of the object I was parsing and it fixed the issue. I guess the values inside the array were actually just referencing to something that's changing elsewhere in my code.

alawrence
  • 61
  • 1
  • 2