Subject: | Patch for skipHours |
--- /usr/lib/perl5/site_perl/5.8.0/XML/RSS.pm~ 2004-04-21
03:14:43.000000000 -0400
+++ /usr/lib/perl5/site_perl/5.8.0/XML/RSS.pm 2010-07-25
17:51:47.000000000 -0400
@@ -768,7 +768,12 @@
#####################
if ($self->{skipHours}->{hour}) {
$output .= '<skipHours>'."\n";
- $output .= '<hour>'. $self->encode($self->{skipHours}->{hour})
.'</hour>'."\n";
+ if ( ref($self->{skipHours}->{hour}) eq 'ARRAY' ){
+ $output .= '<hour>'. $self->encode($_) .'</hour>'."\n"
foreach @{$self->{skipHours}->{hour}};
+ }
+ else{
+ $output .=
'<hour>'.$self->encode($self->{skipHours}->{hour}).'</hour>'."\n";
+ }
$output .= '</skipHours>'."\n\n";
}
@@ -1263,7 +1268,12 @@
#####################
if ($self->{skipHours}->{hour}) {
$output .= '<skipHours>'."\n";
- $output .=
'<hour>'.$self->encode($self->{skipHours}->{hour}).'</hour>'."\n";
+ if ( ref($self->{skipHours}->{hour}) eq 'ARRAY' ){
+ $output .= '<hour>'. $self->encode($_) .'</hour>'."\n"
foreach @{$self->{skipHours}->{hour}};
+ }
+ else{
+ $output .=
'<hour>'.$self->encode($self->{skipHours}->{hour}).'</hour>'."\n";
+ }
$output .= '</skipHours>'."\n\n";
}