Files
racalmas/lib/calcms/mail.pm
Milan d3fc5f998a remove cache
* remove cache, cache setup is not easy, todays servers do not really
* need it anymore
* add prototypes and fix parameter issues
* suppress redefinition
2019-04-22 00:59:40 +02:00

27 lines
482 B
Perl

package mail;
use strict;
use warnings;
no warnings 'redefine';
use MIME::Lite();
sub send($) {
my $mail = shift;
my $msg = MIME::Lite->new(
'From' => $mail->{'From'},
'To' => $mail->{'To'},
'Cc' => $mail->{'Cc'},
'Reply-To' => $mail->{'Reply-To'},
'Subject' => $mail->{'Subject'},
'Data' => $mail->{'Data'},
);
$msg->print( \*STDERR );
$msg->send;
}
# do not delete next line
return 1;