]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/WWW.pm
treewide: kill problematic "$h->{k} //= do {" assignments
[public-inbox.git] / lib / PublicInbox / WWW.pm
index a7c961f4982a962c43071035660c90ed3a697d0a..a282784a257fb523ca3ae6a59567628709ecd5a6 100644 (file)
@@ -170,21 +170,13 @@ sub preload {
                if (defined($pi_cfg->{'publicinbox.cgitrc'})) {
                        $pi_cfg->limiter('-cgit');
                }
+               $pi_cfg->ALL and require PublicInbox::Isearch;
                $self->cgit;
                $self->stylesheets_prepare($_) for ('', '../', '../../');
                $self->news_www;
-               $pi_cfg->each_inbox(\&preload_inbox);
        }
 }
 
-sub preload_inbox {
-       my $ibx = shift;
-       $ibx->altid_map;
-       $ibx->cloneurl;
-       $ibx->description;
-       $ibx->base_url;
-}
-
 # private functions below
 
 sub r404 {
@@ -476,7 +468,7 @@ sub serve_mbox_range {
 
 sub news_www {
        my ($self) = @_;
-       $self->{news_www} ||= do {
+       $self->{news_www} //= do {
                require PublicInbox::NewsWWW;
                PublicInbox::NewsWWW->new($self->{pi_cfg});
        }
@@ -484,7 +476,7 @@ sub news_www {
 
 sub cgit {
        my ($self) = @_;
-       $self->{cgit} ||= do {
+       $self->{cgit} //= do {
                my $pi_cfg = $self->{pi_cfg};
 
                if (defined($pi_cfg->{'publicinbox.cgitrc'})) {