mirror of
https://github.com/webmin/webmin.git
synced 2025-07-20 16:48:46 +00:00
Respect global to address if set
This commit is contained in:
@ -210,7 +210,8 @@ print &ui_table_row($text{'index_sched'},
|
||||
|
||||
# Send email to
|
||||
print &ui_table_row($text{'index_email'},
|
||||
&ui_textbox("email", $config{'sched_email'}, 40));
|
||||
&ui_textbox("email", $config{'sched_email'} ||
|
||||
$gconfig{'webmin_email_to'}, 40));
|
||||
|
||||
# Install or just notify?
|
||||
print &ui_table_row($text{'index_action'},
|
||||
|
@ -56,12 +56,13 @@ if ($tellcount) {
|
||||
}
|
||||
|
||||
# Email the admin
|
||||
if ($config{'sched_email'} && $body) {
|
||||
$emailto = $config{'sched_email'} || $gconfig{'webmin_email_to'};
|
||||
if ($emailto && $body) {
|
||||
&foreign_require("mailboxes", "mailboxes-lib.pl");
|
||||
my $from = &mailboxes::get_from_address();
|
||||
my $mail = { 'headers' =>
|
||||
[ [ 'From', $from ],
|
||||
[ 'To', $config{'sched_email'} ],
|
||||
[ 'To', $emailto ],
|
||||
[ 'Subject', "Package updates on ".
|
||||
&get_system_hostname() ] ],
|
||||
'attach' =>
|
||||
|
Reference in New Issue
Block a user