]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/Linkify.pm
treewide: run update-copyrights from gnulib for 2019
[public-inbox.git] / lib / PublicInbox / Linkify.pm
index af9be3ff1632be1d8f7ede077f982c55501a782e..d176a7cc8eefca89eaa2d549554c7a33a5bd52d7 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2014-2019 all contributors <meta@public-inbox.org>
+# Copyright (C) 2014-2020 all contributors <meta@public-inbox.org>
 # License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>
 
 # two-step linkification.
@@ -70,7 +70,7 @@ sub linkify_1 {
 
                $_[0]->{$key} = $url;
                $beg . 'PI-LINK-'. $key . $end;
-       ^ge;
+       ^geo;
        $_[1];
 }
 
@@ -120,4 +120,6 @@ sub linkify_mids {
        !ge;
 }
 
+sub to_html { linkify_2($_[0], ascii_html(linkify_1(@_))) }
+
 1;