From: Joey Hess Date: Tue, 19 May 2015 21:44:20 +0000 (-0400) Subject: sohrten url in subject X-Git-Tag: 3.20150610~55 X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/commitdiff_plain/3676ab329d40de55fa11b4862cc3fb5350ceedb3?hp=ba02e7f33dbbb7349b61250f9e565db22a9eb4fa sohrten url in subject --- diff --git a/IkiWiki/Plugin/emailauth.pm b/IkiWiki/Plugin/emailauth.pm index a739c2bc7..a589199d3 100644 --- a/IkiWiki/Plugin/emailauth.pm +++ b/IkiWiki/Plugin/emailauth.pm @@ -78,12 +78,14 @@ sub email_auth ($$$$) { eval q{use Mail::Sendmail}; error($@) if $@; + my $shorturl=$config{url}; + $shorturl=~s/^https?:\/\///i; sendmail( To => $email, From => "$config{wikiname} admin <". (defined $config{adminemail} ? $config{adminemail} : "") .">", - Subject => "$config{wikiname} login | ".$config{url}, + Subject => "$config{wikiname} login | $shorturl", Message => $template->output, ) or error(gettext("Failed to send mail"));