ratson / cordova-plugin-admob-free

New development has been moved to "admob-plus-cordova", https://github.com/admob-plus/admob-plus/tree/master/packages/cordova
https://github.com/admob-plus/admob-plus
MIT License
495 stars 211 forks source link

Events are added more than once after viewing a video #324

Open diegoestacho999 opened 5 years ago

diegoestacho999 commented 5 years ago

How to prevent an event from being triggered more than once? If I watch a video, it triggers an event, but when I see the second, it triggers the previous event, plus an event then how to prevent it?

paulmoody commented 5 years ago

@diegoestacho999 use this format:

this.admob.on("admob.rewardvideo.events.CLOSE").subscribe((data) => { / code to execute on CLOSE event here /
}

This won't execute extra events.