Fixing style errors.

This commit is contained in:
stickler-ci 2022-06-08 15:14:18 +00:00
parent bf10e8f687
commit 189d918181

View File

@ -318,7 +318,6 @@ if (empty($reshook)) {
setEventMessages($object->error, $object->errors, 'errors');
$error++;
} else {
//@TODO changer le nom si validated
if ($autoValidation) {
$htemp = new Holiday($db);
@ -336,7 +335,7 @@ if (empty($reshook)) {
if ($AutoSendMail && !$error) {
// send a mail to the user
$returnSendMail = sendMail($result, $cancreate, $now, $autoValidation);
if (!empty($returnSendMail->msg)) setEventMessage($returnSendMail->msg,$returnSendMail->style);
if (!empty($returnSendMail->msg)) setEventMessage($returnSendMail->msg, $returnSendMail->style);
}
}
}
@ -742,19 +741,16 @@ function sendMail($id, $cancreate, $now, $autoValidation)
$result = $mail->sendfile();
if (!$result) {
$objStd->error++;
$objStd->msg = $langs->trans('ErroreSendmail');
$objStd->style="warnings";
$objStd->status = 'error';
} else {
$objStd->msg = $langs->trans('mailSended');
}
return $objStd;
} else {
$objStd->error++;
$objStd->msg = $langs->trans('ErroreVerif');
$objStd->status = 'error';
@ -763,7 +759,6 @@ function sendMail($id, $cancreate, $now, $autoValidation)
}
}
} else {
$objStd->error++;
$objStd->msg = $langs->trans('ErrorloadUserOnSendingMail');
$objStd->status = 'error';