Mass convert to tabs + fix veh buy ownership

This commit is contained in:
Vortrex
2022-04-24 08:18:01 -05:00
parent 429da67b7d
commit 4e86118475
41 changed files with 7535 additions and 7526 deletions

View File

@@ -8,47 +8,47 @@
// ===========================================================================
function initEmailScript() {
if(!checkForSMTPModule()) {
return false;
}
if(!checkForSMTPModule()) {
return false;
}
logToConsole(LOG_INFO, "[VRR.Email]: Initializing email script ...");
emailConfig = loadEmailConfiguration();
emailConfig = loadEmailConfiguration();
logToConsole(LOG_INFO, "[VRR.Email]: Email script initialized successfully!");
}
// ===========================================================================
function sendEmail(toEmail, toName, subject, body) {
if(!checkForSMTPModule()) {
return false;
}
if(!checkForSMTPModule()) {
return false;
}
module.smtp.send(
getEmailConfig().smtp.host,
getEmailConfig().smtp.port,
intToBool(getEmailConfig().smtp.useTLS),
getEmailConfig().smtp.username,
getEmailConfig().smtp.password,
toEmail,
toName,
subject,
body,
getEmailConfig().smtp.from,
getEmailConfig().smtp.fromName);
module.smtp.send(
getEmailConfig().smtp.host,
getEmailConfig().smtp.port,
intToBool(getEmailConfig().smtp.useTLS),
getEmailConfig().smtp.username,
getEmailConfig().smtp.password,
toEmail,
toName,
subject,
body,
getEmailConfig().smtp.from,
getEmailConfig().smtp.fromName);
}
// ===========================================================================
function loadEmailConfiguration() {
let emailConfigFile = loadTextFile("config/email.json");
let emailConfigFile = loadTextFile("config/email.json");
return JSON.parse(emailConfigFile);
}
// ===========================================================================
function getEmailConfig() {
return emailConfig;
return emailConfig;
}
// ===========================================================================