Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

make the main link of the events feed link to the actual event or to …

…the wiki, if it is available
  • Loading branch information...
commit 1488410182436d3a345760f53715f90cc6006b24 1 parent ab62ac5
@szabgab authored
Showing with 9 additions and 1 deletion.
  1. +9 −1 lib/PEG.pm
View
10 lib/PEG.pm
@@ -161,13 +161,21 @@ sub _rss {
my $text = $n->{text} || '';
$text =~ s{"/}{"$base/}g;
+ my $link = $url . ( $n->{permalink} || '' );
+
if ($name eq 'events') {
$text = _event_text($n);
+ my $wiki;
+ if ($n->{wiki}) {
+ $n->{wiki} =~ s/ /_/g;
+ $wiki = "http://perlfoundation.org/perl5/$n->{wiki}";
+ }
+ $link = $wiki || $n->{url} || '';
}
$rss->add_item(
title => decode( 'utf-8', $n->{title} ),
- link => $url . ( $n->{permalink} || '' ),
+ link => $link,
description => decode( 'utf-8', $text ),
dc => {
creator => $n->{author},
Please sign in to comment.
Something went wrong with that request. Please try again.