Skip to content

Commit 7a72816

Browse files
committed
Add comment
1 parent 4e167ba commit 7a72816

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/core/ObservableQuery.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1463,6 +1463,8 @@ Did you mean to call refetch(variables) instead of refetch({ variables })?`,
14631463
info.interval = pollInterval;
14641464

14651465
const maybeFetch = () => {
1466+
// defense against options changing after the setTimeout changes in case
1467+
// the call site forgets to call cancelPolling
14661468
if (shouldCancelPolling()) {
14671469
return this.cancelPolling();
14681470
}

0 commit comments

Comments
 (0)