✅ – dmikester1 – 20-34 Jan 31
I have a route in my Node server with this code:
I cannot get the filled in
linesQCCheckStatus
array to get passed back.3 Replies
The console logs are outputting correctly as I would expect. But in my client code where I make the call, it is always an empty array.
This is my client code where the call is made:
Wow, that was a super tough one to debug!!! Actually had nothing to do with await/async/promises. What I was doing wrong was handling the array like an object. So the console log looked fine, but it wasn't passing it back correctly. All I had to do to fix it was change the array to an object:
let linesQCCheckStatus = {};
This question has an answer! Thank you for helping 😄
If you have a followup question, you may want to reply to this thread so other members know they're related. https://discord.com/channels/102860784329052160/565213527673929729/1070079624433914016
This thread hasn’t had any activity in 12 hours, so it’s now locked.
Threads are closed automatically after 12 hours. If you have a followup question, you may want to reply to this thread so other members know they're related. https://discord.com/channels/102860784329052160/565213527673929729/1070079624433914016
Question not getting answered? Maybe it's hard to answer, or maybe you asked at a slow time. Check out these resources for help asking a good question:
https://stackoverflow.com/help/how-to-ask
http://wp.me/p2oIwo-26