FIX: ensures we have touches when starting pan event (#7435)

This commit is contained in:
Joffrey JAFFEUX
2019-04-25 10:36:41 +02:00
committed by GitHub
parent d8ff94ecaa
commit e386fa7674

View File

@@ -24,7 +24,7 @@ export default Ember.Mixin.create({
addTouchListeners($element) {
if (this.site.mobileView) {
$element
.on("touchstart", e => this._panStart(e.touches[0]))
.on("touchstart", e => e.touches && this._panStart(e.touches[0]))
.on("touchmove", e => {
const touchEvent = e.touches[0];
touchEvent.type = "pointermove";