Merge changes from master

This commit is contained in:
Brian O'Donnell
2015-05-27 10:46:02 -04:00
parent 1619049c86
commit d374ffd0d0
+8 -7
View File
@@ -206,12 +206,15 @@ sub get_feed_items {
foreach my $item ( @$list ){ foreach my $item ( @$list ){
my $link = $item->{'link'}; my $link = $item->{'link'};
my $title =
# no link, no go
next unless defined $link and ref $link ne 'HASH' and ref $link ne 'ARRAY';
my @hashtags = (); my @hashtags = ();
my $guid = ''; my $guid = undef;
# strip trailing / # strip trailing /
$link =~ s/\/+$//; $link =~ s/\/+$// if defined $link;
# add user-specified tags # add user-specified tags
push( @hashtags, @{$params{'auto_tags'}} ) if defined $params{'auto_tags'}; push( @hashtags, @{$params{'auto_tags'}} ) if defined $params{'auto_tags'};
@@ -269,16 +272,14 @@ sub get_feed_items {
if( ref $item->{'guid'} eq 'HASH' and defined $item->{'guid'}->{'content'} ){ if( ref $item->{'guid'} eq 'HASH' and defined $item->{'guid'}->{'content'} ){
$guid = $item->{'guid'}->{'content'}; $guid = $item->{'guid'}->{'content'};
} }
else { elsif( ref $item->{'guid'} ne 'HASH' ) {
$guid = $item->{'guid'}; $guid = $item->{'guid'};
} }
} }
elsif( defined $item->{'id'} ){ elsif( defined $item->{'id'} ){
$guid = $item->{'id'}; $guid = $item->{'id'};
} }
elsif( defined $item->{'link'} ){ else { $guid = $link }
$guid = $item->{'link'};
}
my $obj = { my $obj = {
guid => $guid, guid => $guid,