X-Git-Url: https://git.deb.at/?a=blobdiff_plain;f=lib%2FPackages%2FCGI.pm;h=cc92e64d6f748c6496c7e0205f7df733a62692a7;hb=976d1881dc169228ed327cd52eba12d29bb9bf42;hp=b2b261db705b7c009b9cb62c2534b2c3ed4039a7;hpb=264b1245548e5c5494778a813e5e48897168b008;p=deb%2Fpackages.git diff --git a/lib/Packages/CGI.pm b/lib/Packages/CGI.pm index b2b261d..cc92e64 100644 --- a/lib/Packages/CGI.pm +++ b/lib/Packages/CGI.pm @@ -31,14 +31,11 @@ sub msg { push @msgs, $_[0]; } sub note { - push @notes, $_[0]; -} -sub notes { push @notes, [ @_ ]; } sub print_errors { return unless @fatal_errors || @errors; - print '
'; + print '
'; foreach ((@fatal_errors, @errors)) { print "

ERROR: $_

"; } @@ -46,7 +43,7 @@ sub print_errors { } sub print_debug { return unless $debug && @debug; - print '
'; + print '
'; print '

Debugging:

';
     foreach (@debug) {
 	print "$_\n";
@@ -55,7 +52,7 @@ sub print_debug {
 }
 sub print_hints {
     return unless @hints;
-    print '
'; + print '
'; foreach (@hints) { print "

$_

"; } @@ -69,15 +66,14 @@ sub print_msgs { sub print_notes { foreach (@notes) { my ( $title, $note ) = @$_; - my $str = ""; + print '
'; if ($note) { - $str .= "

$title

"; + print "

$title

"; } else { $note = $title; } - $str .= "

$note

"; - return $str; + print "

$note

"; } }