MV Using nodemailer in RPG maker MV

Hi there,

This is my first time using RPG maker and I'm trying to create an event that will send an email to the player after they input an email address.

I found the javascript for this in the following thread https://forums.rpgmakerweb.com/index.php?threads/send-an-email-from-inside-the-game.124669/

It seems to have worked for those users but when I tried to do it I get a syntax error as follows:

js.JPG


does this mean the problem is in the code of nodemailer?

This seems to be the relevant line in the nodemailer code

scrip.JPG


Any help would be greatly appreciated.

Original thread: https://forums.rpgmakerweb.com/threads/using-nodemailer-in-rpg-maker-mv.146497/