Kanaries / Rath

Next generation of automated data exploratory analysis and visualization platform.
https://kanaries.net
GNU Affero General Public License v3.0
4.29k stars 335 forks source link

[feat] email format check #188

Closed github-actions[bot] closed 1 year ago

github-actions[bot] commented 2 years ago

console.log("mail sent success");

https://github.com/Kanaries/Rath/blob/fe41774375c795ea0335014cc8577d8e5c372691/packages/rath-client/src/hooks/index.ts#L60


async function sendCertMail(email: string) {
    const url = getServerUrl('/api/sendMailCert');
    // TODO: [feat] email format check
    const res = await request.post<{ email: string }, string>(url, { email });
    if (res) {
        // console.log("mail sent success");
    }
    return res;
}

async function sendCertPhone(phone: string) {
    const url = getServerUrl('/api/sendPhoneCert');
    const res = await request.post<{ phone: string }, string>(url, { phone });
    if (res) {
        // console.log("message sent success");
    }
    return res;
}
github-actions[bot] commented 1 year ago

Closed in 7b8d7512026da6dba3f25a728835723a84a38e25