Below, you can see the output from these two logs. The first clearly shows the full object with the property I\'m trying to access, but on the very next line of code, I can\
My data was just json data string . (This variable was stored as json string in the session).
console.log(json_string_object)
-> returns just the representation of this string and there is no way to make difference whether is string or object.
So to make it work I just needed to convert it back to real object:
object = JSON.parse(json_string_object);