Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: touchCache should be var or let, not const #34653

Merged
merged 4 commits into from
Jul 6, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Update index.md
  • Loading branch information
ragul1697 committed Jul 5, 2024
commit 2895bf1a41913b7723bd1d5a3c8cd5977bea766e
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,14 @@ function handle_pinch_zoom(ev) {
ev.target.style.background = "green";
} else {
// empty tpCache
tpCache = [];
clearTouchCache();
}
}
}

function clearTouchCache() {
tpCache.length = 0;
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think a separate function is not necessary here

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, Now I moved it to the else part

```

### Touch start handler
Expand Down