comparison scan.pl @ 254:1e4922d9a671

fixed for saving island data.
author "Rex Tsai <chihchun@kalug.linux.org.tw>"
date Mon, 17 Nov 2008 13:01:10 +0800
parents d75f26fc1c69
children b01560b95779
comparison
equal deleted inserted replaced
253:9fe03a3d155c 254:1e4922d9a671
125 # 10 minutes cache. 125 # 10 minutes cache.
126 if($island->time le (time - 60*10)) { 126 if($island->time le (time - 60*10)) {
127 my $i = $self->{ikariam}->clone(); 127 my $i = $self->{ikariam}->clone();
128 my @cities = 128 my @cities =
129 $i->viewIsland($h_island->{id}); 129 $i->viewIsland($h_island->{id});
130 $self->saveCities($h_island->{id}, @cities);
131
132 $island->set('time', time); 130 $island->set('time', time);
133 } 131 }
134 $island->update(); 132 $island->update();
133
134 $self->saveCities($h_island->{id}, @cities);
135 $pm->finish; 135 $pm->finish;
136 } 136 }
137 $pm->wait_all_children; 137 $pm->wait_all_children;
138 } 138 }
139 139