``` if (recipientEmail){ ...
# suitescript
z
Copy code
if (recipientEmail){
            email.send({
                author: senderId,
                recipients: recipientEmail,
                subject: 'Here is your Statement from ' + begdate + ' to ' + enddate,
                body: 'Your Statement is below:',
                attachments: [newfile],
                relatedRecords: {
                	entityId: ownerInternalID
                }
            });
            }