Short-circuit when there's no handle available.
Patch by kareila.
diffs (12 lines):
diff -r 40d459a3001c -r 8c33e8a914f5 cgi-bin/LJ/Entry.pm
--- a/cgi-bin/LJ/Entry.pm Sat Aug 28 14:08:48 2010 +0800
+++ b/cgi-bin/LJ/Entry.pm Sat Aug 28 14:11:23 2010 +0800
@@ -1703,7 +1703,7 @@ sub get_itemid_near2
return 0;
}
- my $dbr = LJ::get_cluster_reader($u);
+ my $dbr = LJ::get_cluster_reader($u) or return 0;
my $jid = $u->{'userid'}+0;
my $field = $u->is_person ? "revttime" : "rlogtime";
_______________________________________________
dw-changelog mailing list
[email protected]
http://lists.dwscoalition.org/mailman/listinfo/dw-changelog