juks (juks) wrote in changelog,
juks
juks
changelog

[livejournal] r17955: r74 botcheck warning fix

Committer: iaskarov
r74 botcheck warning fix
U   trunk/cgi-bin/BotCheck.pm
Modified: trunk/cgi-bin/BotCheck.pm
===================================================================
--- trunk/cgi-bin/BotCheck.pm	2010-12-17 05:05:58 UTC (rev 17954)
+++ trunk/cgi-bin/BotCheck.pm	2010-12-17 05:18:09 UTC (rev 17955)
@@ -122,7 +122,7 @@
 sub is_bot {
 	my ($class, $useragent) = @_;
 		
-	return $useragent =~ $crawler_agents;
+	return defined $useragent ? $useragent =~ $crawler_agents ne "" : 0;
 }
 
 1;

Tags: juks, livejournal, pm
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments