From: minima Date: Wed, 31 Aug 2005 19:05:18 +0000 (+0000) Subject: fix the problem now created with spots with no text X-Git-Tag: 1.54~198 X-Git-Url: http://dxcluster.net/gitweb/gitweb.cgi?p=spider.git;a=commitdiff_plain;h=90d957b802f7b48c10a98521a5c7ca387d2fa1c0 fix the problem now created with spots with no text --- diff --git a/perl/Spot.pm b/perl/Spot.pm index f331d105..9a4b9724 100644 --- a/perl/Spot.pm +++ b/perl/Spot.pm @@ -350,12 +350,14 @@ sub dup my $ldupkey = "X$freq|$call|$by|$text"; my $t = DXDupe::find($ldupkey); return 1 if $t && $t - $main::systime > 0; - DXDupe::add($ldupkey, $main::systime+$dupage); - $otext = substr($otext, 0, $duplth) if length $otext > $duplth; - $ldupkey = "X$freq|$call|$by|$otext"; - $t = DXDupe::find($ldupkey); - return 1 if $t && $t - $main::systime > 0; - DXDupe::add($ldupkey, $main::systime+$dupage); + if ($otext) { + DXDupe::add($ldupkey, $main::systime+$dupage); + $otext = substr($otext, 0, $duplth) if length $otext > $duplth; + $ldupkey = "X$freq|$call|$by|$otext"; + $t = DXDupe::find($ldupkey); + return 1 if $t && $t - $main::systime > 0; + DXDupe::add($ldupkey, $main::systime+$dupage); + } # my $sdupkey = "X$freq|$call|$by"; # $t = DXDupe::find($sdupkey); # return 1 if $t && $t - $main::systime > 0;