namaste-javascript-notes icon indicating copy to clipboard operation
namaste-javascript-notes copied to clipboard

Incorrect variable reference and log output in async/await explanation for `p1` and `p2` in episode 23.

Open rishav1729 opened this issue 7 months ago • 0 comments

In the section explaining the call stack behavior with async/await, there's a mismatch between the code snippet and the explanation text.

Image

Issue:

In the descriptive explanation that follows this code, the variable p is incorrectly referenced instead of p1, and the resolved value log 'Promise resolved value!!' is incorrect. It should match the actual resolved value in the code: 'Promise resolved value by p1!!'.

Problematic explanation excerpt:

...Now it will log 'Hello There!' and 'Promise resolved value!!'...

Suggested fix:

Update the explanation to correctly refer to:

...Now it will log 'Hello There!' and 'Promise resolved value by p1!!'...

This ensures consistency between the code and the explanation for better clarity and learning.

rishav1729 avatar May 17 '25 13:05 rishav1729