]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/WwwListing.pm
www: improve navigation around contemporary threads
[public-inbox.git] / lib / PublicInbox / WwwListing.pm
index 5f85e3464bc84d9b76986ddedd313cb30347f168..365743cfdf90d13bc4b56b95297dc1d04e93f716 100644 (file)
@@ -6,7 +6,7 @@
 package PublicInbox::WwwListing;
 use strict;
 use warnings;
-use PublicInbox::Hval qw(ascii_html prurl);
+use PublicInbox::Hval qw(ascii_html prurl fmt_ts);
 use PublicInbox::Linkify;
 use PublicInbox::View;
 use PublicInbox::Inbox;
@@ -40,7 +40,7 @@ sub list_all ($$$) {
 sub list_match_domain_i {
        my ($ibx, $arg) = @_;
        my ($list, $hide_key, $re) = @$arg;
-       if (!$ibx->{-hide}->{$hide_key} && grep($re, @{$ibx->{url}})) {
+       if (!$ibx->{-hide}->{$hide_key} && grep(/$re/, @{$ibx->{url}})) {
                push @$list, $ibx;
        }
 }
@@ -91,7 +91,7 @@ sub new {
 
 sub ibx_entry {
        my ($mtime, $ibx, $env) = @_;
-       my $ts = PublicInbox::View::fmt_ts($mtime);
+       my $ts = fmt_ts($mtime);
        my $url = prurl($env, $ibx->{url});
        my $tmp = <<"";
 * $ts - $url