about summary refs log tree commit homepage
path: root/lib/PublicInbox/Unsubscribe.pm
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2016-05-21 04:12:45 +0000
committerEric Wong <e@80x24.org>2016-05-21 04:12:45 +0000
commit2ec1ac4a259c87ad453195fa405c6aa7d99d7cb7 (patch)
tree9460edca49af99fba6b2ed61ef2c755d3f26bcc1 /lib/PublicInbox/Unsubscribe.pm
parent1f29b33d3f71b8a40f5ae76bf20b95618b518654 (diff)
downloadpublic-inbox-2ec1ac4a259c87ad453195fa405c6aa7d99d7cb7.tar.gz
Fixup a comment about s/query string/PATH_INFO/ while
we're at it, as pre-published versions of this used
query strings before I determined it could be harder
to copy+paste URLs with query parameters in them.
Diffstat (limited to 'lib/PublicInbox/Unsubscribe.pm')
-rw-r--r--lib/PublicInbox/Unsubscribe.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/PublicInbox/Unsubscribe.pm b/lib/PublicInbox/Unsubscribe.pm
index 1f5ce315..4ccdb7e0 100644
--- a/lib/PublicInbox/Unsubscribe.pm
+++ b/lib/PublicInbox/Unsubscribe.pm
@@ -77,7 +77,7 @@ sub _user_list_addr {
                         'Missing mailing list name in path component');
         }
         my $user = eval { $self->{cipher}->decrypt(decode_base64url($u)) };
-        if (!defined $user) {
+        if (!defined $user || $user eq '') {
                 my $err = quotemeta($@);
                 my $errors = $env->{'psgi.errors'};
                 $errors->print("error decrypting: $u\n");
@@ -86,7 +86,7 @@ sub _user_list_addr {
         }
 
         # The URLs are too damn long if we have the encrypted domain
-        # name in the query string
+        # name in the PATH_INFO
         if (index($list, '@') < 0) {
                 my $host = (split(':', $env->{HTTP_HOST}))[0];
                 $list .= '@'.$host;