From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: X-Spam-Status: No, score=-2.7 required=3.0 tests=ALL_TRUSTED,AWL,BAYES_00 shortcircuit=no autolearn=unavailable version=3.3.2 X-Original-To: meta@public-inbox.org Received: from localhost (dcvr.yhbt.net [127.0.0.1]) by dcvr.yhbt.net (Postfix) with ESMTP id 4D2442021F for ; Sat, 9 Jan 2016 09:45:59 +0000 (UTC) From: Eric Wong To: meta@public-inbox.org Subject: [PATCH 2/3] hval: new should not strip leading spaces Date: Sat, 9 Jan 2016 09:45:21 +0000 Message-Id: <20160109094522.2484-3-e@80x24.org> In-Reply-To: <20160109094522.2484-1-e@80x24.org> References: <20160109094522.2484-1-e@80x24.org> List-Id: We should be able to use this for ASCII art and paragraphs --- lib/PublicInbox/Hval.pm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/PublicInbox/Hval.pm b/lib/PublicInbox/Hval.pm index 5a86935..d295f5c 100644 --- a/lib/PublicInbox/Hval.pm +++ b/lib/PublicInbox/Hval.pm @@ -21,8 +21,7 @@ my $enc_ascii = find_encoding('us-ascii'); sub new { my ($class, $raw, $href) = @_; - # we never care about leading/trailing whitespace - $raw =~ s/\A\s*//; + # we never care about trailing whitespace $raw =~ s/\s*\z//; bless { raw => $raw, -- EW