changeset 249:c30080146c05

fixed the sheep.pl for ignore user without ally
author "Rex Tsai <chihchun@kalug.linux.org.tw>"
date Mon, 17 Nov 2008 00:25:56 +0800
parents fd6c3660cd38
children a654d43731f0
files sheep.pl
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/sheep.pl	Fri Nov 14 02:05:48 2008 +0800
+++ b/sheep.pl	Mon Nov 17 00:25:56 2008 +0800
@@ -59,6 +59,7 @@
                 unless ($sheep->allyId == '0') {
                     unless (!defined($sheep->allyId) || $sheep->allyId == 0) {
                         my $ally = Ikariam::Ally->retrieve($sheep->allyId);
+                        next if(!defined($ally));
                         next if($ally->score > $myAlly->score);
                     }
                 }