X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/3676ab329d40de55fa11b4862cc3fb5350ceedb3..c7bdebaaf134729356852918b387071c92f85e72:/IkiWiki/Plugin/emailauth.pm?ds=sidebyside diff --git a/IkiWiki/Plugin/emailauth.pm b/IkiWiki/Plugin/emailauth.pm index a589199d3..6674fe3d6 100644 --- a/IkiWiki/Plugin/emailauth.pm +++ b/IkiWiki/Plugin/emailauth.pm @@ -26,6 +26,12 @@ sub getsetup () { rebuild => 0, section => "auth", }, + emailauth_sender => { + type => "string", + description => "email address to send emailauth mails as (default: adminemail)", + safe => 1, + rebuild => 0, + }, } sub email_setup ($$) { @@ -80,10 +86,12 @@ sub email_auth ($$$$) { error($@) if $@; my $shorturl=$config{url}; $shorturl=~s/^https?:\/\///i; + my $emailauth_sender=$config{emailauth_sender}; + $emailauth_sender=$config{adminemail} unless defined $emailauth_sender; sendmail( To => $email, From => "$config{wikiname} admin <". - (defined $config{adminemail} ? $config{adminemail} : "") + (defined $emailauth_sender ? $emailauth_sender : "") .">", Subject => "$config{wikiname} login | $shorturl", Message => $template->output,