OnSend fired twice after attachment reminder

Viewed 377

In Outlook Web Add-In, I'm trying to intercept OnSend event which is triggered when sending an email.

I used this example in GitHub which is working fine.

If I include the word "attachment" in the email body and I click Send button, OnSend event is fired once and a pop-up modal window shows up with this message:

Attachment reminder

You may have forgotten to attach a file.

with Send and Don't send buttons. If click Send, OnSend event get fired twice: 2 times after clicking Send button within attachment reminder. I was expecting only one event like the first Send.

How can I make OnSend event fire once after the attachment reminder?

2 Answers
Related