REALLY URGENT--Small error with onItemReady

I get this error when i try to send a sendgrid email with onItemReady.Somebody could help me?

The “onItemReady” function of “repeater1” threw the following error: Cannot read property ‘getDate’ of undefined
; (745 LINE)

$w(“#uploadButton1”).startUpload()
.then((uploadedFile) => {
$w(“#repeater1”).onItemReady(($item, itemData, index) => {
let language = itemData.language;

if (language === “EN”) {

let recipient = itemData.email;
send4(uploadedFile, recipient);

                }  **else**  { 

let recipient = itemData.email;
send3(uploadedFile, recipient);

                } 

            }); 
        })

UP Please is really urgent

Are you following any tutorial or trying to hash together your own code for it?

https://support.wix.com/en/article/corvid-tutorial-sending-an-email-on-form-submission
https://www.wix.com/corvid/forum/corvid-tips-and-updates/example-send-email-with-the-sendgrid-rest-interface
https://www.wix.com/corvid/forum/corvid-tips-and-updates/example-send-email-with-the-sendgrid-rest-interface

Also, if you are trying to add this into a repeater, which I don’t think would be a good idea, then have a read of Repeater and it’s own onItemReady function from the Wix API reference,
https://www.wix.com/corvid/reference/$w.Repeater.html
https://www.wix.com/corvid/reference/$w.Repeater.html#onItemReady

I coded everything,works but i get this error and i don’t know why.
I want to send an email to a list of recipients collected in a repeater linked to a database.
I used onItemReady because forEachItem doesn’t work.

Well look at your original error of ‘Cannot read property ‘getDate’ of undefined’.

That indicates that you are not finding a value for the getDate property that is in your code somewhere.