Skip to content

Commit

Permalink
fix: make iterator pointer proxy iterable
Browse files Browse the repository at this point in the history
  • Loading branch information
ZLY201 committed Jul 10, 2023
1 parent 571a439 commit 09c7653
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/container/HashContainer/HashMap.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class HashMapIterator<K, V> extends HashContainerIterator<K, V> {
throwIteratorAccessError();
}
const self = this;
return new Proxy(<[K, V]><unknown>[self._node._key, self._node._value], {
return new Proxy(<[K, V]><unknown>[], {
get(target, prop: '0' | '1') {
if (prop === '0') return self._node._key;
else if (prop === '1') return self._node._value;
Expand Down

0 comments on commit 09c7653

Please sign in to comment.