Committer: sbelyaev
LJSUP-12507: should not work PingBack bot for repost entryU trunk/cgi-bin/LJ/PingBack.pm U trunk/cgi-bin/TheSchwartz/Worker/NotifyPingbackServer.pm
Modified: trunk/cgi-bin/LJ/PingBack.pm =================================================================== --- trunk/cgi-bin/LJ/PingBack.pm 2012-06-08 11:01:12 UTC (rev 22211) +++ trunk/cgi-bin/LJ/PingBack.pm 2012-06-08 12:10:37 UTC (rev 22212) @@ -21,10 +21,6 @@ return "Unknown entry"; } - if ($target_entry->original_post) { - return "fast repost"; - } - # empty object means, that sourceURI is not LJ.com's page. # it's an usual case. my $source_entry = LJ::Entry->new_from_url($sourceURI); @@ -99,6 +95,7 @@ return 0 if $LJ::DISABLED{'pingback_receive'}; return 0 if $target_entry->is_suspended; + # Pingback is open for all users # return 0 unless $target_entry->journal->get_cap('pingback'); Modified: trunk/cgi-bin/TheSchwartz/Worker/NotifyPingbackServer.pm =================================================================== --- trunk/cgi-bin/TheSchwartz/Worker/NotifyPingbackServer.pm 2012-06-08 11:01:12 UTC (rev 22211) +++ trunk/cgi-bin/TheSchwartz/Worker/NotifyPingbackServer.pm 2012-06-08 12:10:37 UTC (rev 22212) @@ -35,7 +35,9 @@ foreach my $link (@links){ my $target_entry = LJ::Entry->new_from_url($link->{uri}); + next unless $target_entry; + next unless $target_entry->original_url; next unless LJ::PingBack->should_entry_recieve_pingback($target_entry); next unless log_ping($source_entry, $target_entry);