Files
racalmas/lib/calcms/mail.pm
Milan a6b656779b refactoring
update package definition
fix dependencies
remove global variables
2018-09-02 09:39:24 +02:00

25 lines
403 B
Perl

package mail;
use warnings;
use strict;
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;