Fix typo in map.ts (#121279)

* Fix typo in map.ts

happend -> happened

* Fix typo in map.ts

fixed comment
This commit is contained in:
Ikko Ashimine 2021-04-19 07:08:56 +09:00 committed by GitHub
parent 2288da484d
commit 8aff878db2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -887,7 +887,7 @@ export class LinkedMap<K, V> implements Map<K, V> {
this._tail = undefined;
}
else if (item === this._head) {
// This can only happend if size === 1 which is handle
// This can only happen if size === 1 which is handled
// by the case above.
if (!item.next) {
throw new Error('Invalid list');
@ -896,7 +896,7 @@ export class LinkedMap<K, V> implements Map<K, V> {
this._head = item.next;
}
else if (item === this._tail) {
// This can only happend if size === 1 which is handle
// This can only happen if size === 1 which is handled
// by the case above.
if (!item.previous) {
throw new Error('Invalid list');