From 0fdebc22a878aa9bd791103c8878eeb82e006b2d Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Wed, 15 Dec 2010 04:22:36 +0100 Subject: [PATCH] browser: assume notes are valid html Latest database-derived data no longer contains invalid entities, just linebreaks not represented by html in #video. --- browser.plp | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/browser.plp b/browser.plp index aaafa03..7c494e9 100644 --- a/browser.plp +++ b/browser.plp @@ -236,7 +236,8 @@ sub saytitlecol { } $row->{title}; print '
'; s/\.?$/./, print "

$_

" for map { ref $_ ? @$_ : $_ || () } - Entity($row->{description}), formathtml($row->{notes}); # sic + Entity($row->{description}), + map { s/\s*\n/\n
/g; $_ } $row->{notes}; printf 'Resources: %s.', join(', ', map { sprintf '%s', EscapeHTML($_->{url}), $_->{title} } @$_) for grep { @$_ } $row->{links} // (); @@ -310,16 +311,6 @@ for my $id (sort { say ''; say ''; -sub formathtml { - my $ref = defined wantarray ? [@_] : \@_; - for (@$ref) { - s/& (?!\w)/&/gx; - s/< \s/</gx; - s/\n\K\n/
/g; - } - return @$ref; -} - sub paddedver { # normalised version number comparable as string (cmp) shift =~ /(?:.*-|^)(\d*)(.*)/; -- 2.30.0