]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/Inbox.pm
www_stream: fix search for new.html endpoint
[public-inbox.git] / lib / PublicInbox / Inbox.pm
index 34191fc79508f04ff9ce00cc3782333dd1c033bf..ada713c741657ef16522d4b118cffebcbd95c4be 100644 (file)
@@ -99,7 +99,9 @@ sub nntp_usable {
 sub msg_by_path ($$;$) {
        my ($self, $path, $ref) = @_;
        # TODO: allow other refs:
-       git($self)->cat_file('HEAD:'.$path, $ref);
+       my $str = git($self)->cat_file('HEAD:'.$path, $ref);
+       $$str =~ s/\A[\r\n]*From [^\r\n]*\r?\n//s if $str;
+       $str;
 }
 
 sub msg_by_mid ($$;$) {