how to access and show the contact email selected by the user?

I created a code that allows me at the click of a button to send an email to the user registered with a randomly generated code.

on the page there is a text that reports the email to which the message will be sent.

The point is that if the email is the one with which the user has logged in, there are no problems, instead if the user logs in but then from the settings of his account he changes the email with which he will be contacted when he presses the button the e-mail will reach him in the selected box but the text above the button to show him which e-mail will be sent to does not change, always shows the login e-mail.

How can I access the contact email modified by the user?

Log in email:

Modified and saved email

Email shown

Button page code

import wixData from 'wix-data';
import wixUsers from 'wix-users';
import wixLocation from 'wix-location';

$w.onReady(function () {
    wixUsers.currentUser.getEmail()
    .then( (email) => {
    $w('#loginEmail').text= email
  } );
});

export function button1_click(event) {
 let userEmail= $w('#txtEmail').text;
 let discountCode = Math.floor(Math.random() * 8999+ 1000).toString() ;
 let userId = wixUsers.currentUser.id;
 
    console.log(userEmail)
 
 let toinsert = {
 "member": userId,
 "email": userEmail,
 "codiceSconto": discountCode,
 "codiceInviato": true
    };

    wixData.insert('Codicisconto', toinsert)
    $w('#dbCodiciSconto').save()
        .catch((err) => {
            console.log(err);
            $w('#txtError').show();
        });
    console.log('Inserito nel database')

    wixUsers.emailUser('S2A6sCb', userId, {
            variables: {
                codiceSconto: discountCode
            }
        })
        .then(() => {
            console.log('mail inviata')
            $w('#button1').disable();
            wixLocation.to(`/account/my-account`)
        })

}