Skip to content

Commit 8486142

Browse files
committed
Fix variable access
1 parent ac8178d commit 8486142

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,11 +114,13 @@ export function createHooks<Paths extends {}>(
114114
};
115115
}
116116

117+
const localMatchKeyComparator = matchKeyComparator;
118+
117119
return {
118120
use,
119121
useInfinite,
120122
get matchKey() {
121-
if (!matchKeyComparator) {
123+
if (!localMatchKeyComparator) {
122124
throw new Error(
123125
"Match key comparison is not enabled. Please call enableMatchKeyComparison with a comparator function.",
124126
);

0 commit comments

Comments
 (0)