ionic-long-press icon indicating copy to clipboard operation
ionic-long-press copied to clipboard

[ERROR] Syntax

Open Caldarelli opened this issue 4 years ago • 0 comments

` import { Injectable } from '@angular/core' import { HammerGestureConfig } from '@angular/platform-browser'

@Injectable() export class IonicGestureConfig extends HammerGestureConfig { buildHammer(element: HTMLElement) { if (window) { const mc = new (window).Hammer(element)

  for (const eventName in this.overrides) {
    if (eventName) {
      mc.get(eventName).set(this.overrides[eventName])
    }
  }
}

return mc

} }`

here your "return mc" is outside of the scope of the if statement, shouldn't it be inside?

Caldarelli avatar Jul 01 '20 13:07 Caldarelli