Skip to content

Commit 8b4f5a7

Browse files
committed
minor correction
1 parent 0d064ad commit 8b4f5a7

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Diff for: 18_Day_Promises/18_day_promises.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ square(2)
197197
Promise {<resolved>: 4}
198198
```
199199

200-
The word _async_ in front of a function means that function will return a promise. The above square function instead of a value it returned a promise.
200+
The word _async_ in front of a function means that function will return a promise. The above square function instead of a value it returns a promise.
201201

202202
How do we access the value from the promise? To access the value from the promise, we will use the keyword _await_.
203203

@@ -206,6 +206,7 @@ const square = async function (n) {
206206
return n * n
207207
}
208208
const value = await square(2)
209+
console.log(value)
209210
```
210211

211212
```sh

0 commit comments

Comments
 (0)