Skip to content

Commit e307bd1

Browse files
committed
Typo on README.md
I believe `headers.entries()` returns a *Map#entries()* like iterator so that `[key, value]` would work while `(key, value)` won't do what people think it does.
1 parent 23f5755 commit e307bd1

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -486,10 +486,10 @@ headers.set('Content-Type', 'application/json')
486486
headers.add('Accept', 'application/json')
487487
headers.add('Accept', 'text/html')
488488

489-
for (const (name, value) of headers.entries()) {
490-
// ('Content-Type', 'application/json')
491-
// ('Accept', 'application/json')
492-
// ('Accept', 'text/html')
489+
for (const [name, value] of headers.entries()) {
490+
// ['Content-Type', 'application/json']
491+
// ['Accept', 'application/json']
492+
// ['Accept', 'text/html']
493493
}
494494
```
495495

0 commit comments

Comments
 (0)