@@ -55,7 +55,9 @@ |
||
| 55 | 55 | public function getDescription() |
| 56 | 56 | { |
| 57 | 57 | $desc = $this->getDatabaseDescription(); |
| 58 | - if ($desc === NULL || empty($desc)) $desc = str_format(localize("customcolumn.description"), $this->getTitle()); |
|
| 58 | + if ($desc === NULL || empty($desc)) { |
|
| 59 | + $desc = str_format(localize("customcolumn.description"), $this->getTitle()); |
|
| 60 | + } |
|
| 59 | 61 | return $desc; |
| 60 | 62 | } |
| 61 | 63 | |
@@ -55,7 +55,9 @@ |
||
| 55 | 55 | public function getDescription() |
| 56 | 56 | { |
| 57 | 57 | $desc = $this->getDatabaseDescription(); |
| 58 | - if ($desc === NULL || empty($desc)) $desc = str_format(localize("customcolumn.description"), $this->getTitle()); |
|
| 58 | + if ($desc === NULL || empty($desc)) { |
|
| 59 | + $desc = str_format(localize("customcolumn.description"), $this->getTitle()); |
|
| 60 | + } |
|
| 59 | 61 | return $desc; |
| 60 | 62 | } |
| 61 | 63 | |
@@ -55,7 +55,9 @@ |
||
| 55 | 55 | public function getDescription() |
| 56 | 56 | { |
| 57 | 57 | $desc = $this->getDatabaseDescription(); |
| 58 | - if ($desc === NULL || empty($desc)) $desc = str_format(localize("customcolumn.description"), $this->getTitle()); |
|
| 58 | + if ($desc === NULL || empty($desc)) { |
|
| 59 | + $desc = str_format(localize("customcolumn.description"), $this->getTitle()); |
|
| 60 | + } |
|
| 59 | 61 | return $desc; |
| 60 | 62 | } |
| 61 | 63 | |
@@ -3,7 +3,8 @@ discard block |
||
| 3 | 3 | require_once dirname(__FILE__) . '/config.php'; |
| 4 | 4 | require_once dirname(__FILE__) . '/base.php'; |
| 5 | 5 | |
| 6 | -function checkConfiguration () { |
|
| 6 | +function checkConfiguration () |
|
| 7 | +{ |
|
| 7 | 8 | global $config; |
| 8 | 9 | |
| 9 | 10 | if (is_null ($config['cops_mail_configuration']) || |
@@ -15,7 +16,8 @@ discard block |
||
| 15 | 16 | return False; |
| 16 | 17 | } |
| 17 | 18 | |
| 18 | -function checkRequest ($idData, $emailDest) { |
|
| 19 | +function checkRequest ($idData, $emailDest) |
|
| 20 | +{ |
|
| 19 | 21 | if (empty ($idData)) { |
| 20 | 22 | return 'No data sent.'; |
| 21 | 23 | } |
@@ -59,10 +61,18 @@ discard block |
||
| 59 | 61 | $mail->Port = 465; |
| 60 | 62 | } |
| 61 | 63 | $mail->SMTPAuth = !empty ($config['cops_mail_configuration']["smtp.username"]); |
| 62 | -if (!empty ($config['cops_mail_configuration']["smtp.username"])) $mail->Username = $config['cops_mail_configuration']["smtp.username"]; |
|
| 63 | -if (!empty ($config['cops_mail_configuration']["smtp.password"])) $mail->Password = $config['cops_mail_configuration']["smtp.password"]; |
|
| 64 | -if (!empty ($config['cops_mail_configuration']["smtp.secure"])) $mail->SMTPSecure = $config['cops_mail_configuration']["smtp.secure"]; |
|
| 65 | -if (!empty ($config['cops_mail_configuration']["smtp.port"])) $mail->Port = $config['cops_mail_configuration']["smtp.port"]; |
|
| 64 | +if (!empty ($config['cops_mail_configuration']["smtp.username"])) { |
|
| 65 | + $mail->Username = $config['cops_mail_configuration']["smtp.username"]; |
|
| 66 | +} |
|
| 67 | +if (!empty ($config['cops_mail_configuration']["smtp.password"])) { |
|
| 68 | + $mail->Password = $config['cops_mail_configuration']["smtp.password"]; |
|
| 69 | +} |
|
| 70 | +if (!empty ($config['cops_mail_configuration']["smtp.secure"])) { |
|
| 71 | + $mail->SMTPSecure = $config['cops_mail_configuration']["smtp.secure"]; |
|
| 72 | +} |
|
| 73 | +if (!empty ($config['cops_mail_configuration']["smtp.port"])) { |
|
| 74 | + $mail->Port = $config['cops_mail_configuration']["smtp.port"]; |
|
| 75 | +} |
|
| 66 | 76 | |
| 67 | 77 | $mail->From = $config['cops_mail_configuration']["address.from"]; |
| 68 | 78 | $mail->FromName = $config['cops_title_default']; |