summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBirte Kristina Friesel <derf@finalrewind.org>2024-01-14 13:33:14 +0100
committerBirte Kristina Friesel <derf@finalrewind.org>2024-01-14 13:33:14 +0100
commit827751e430b96a2112b79ee1ffce3a22aec43bdd (patch)
tree639c25446cf386e9a80c991780f2e079f7501015
parenta474981f6a7cb3b67d84ed337ecf2521cd9ef000 (diff)
confirm_mail: work around funky MUAs2.5.11
-rw-r--r--lib/Travelynx/Controller/Account.pm9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/Travelynx/Controller/Account.pm b/lib/Travelynx/Controller/Account.pm
index 0d12fb8..f1dc43e 100644
--- a/lib/Travelynx/Controller/Account.pm
+++ b/lib/Travelynx/Controller/Account.pm
@@ -1218,6 +1218,15 @@ sub confirm_mail {
my $id = $self->current_user->{id};
my $token = $self->stash('token');
+ # Some mail clients include the trailing ">" from the confirmation mail
+ # when opening/copying the confirmation link. A token will never contain
+ # this symbol, so remove it just in case.
+ $token =~ s{>}{};
+
+ # I did not yet find a mail client that also includes the trailing ",",
+ # but you never now...
+ $token =~ s{,}{};
+
if (
$self->users->change_mail_with_token(
uid => $id,