]> ruin.nu Git - NDIRC.git/commitdiff
Fix to recognize that a url is not a command
authorMichael Andreen <harv@ruin.nu>
Fri, 5 Jun 2009 15:32:43 +0000 (17:32 +0200)
committerMichael Andreen <harv@ruin.nu>
Fri, 5 Jun 2009 15:32:43 +0000 (17:32 +0200)
Misc.pm

diff --git a/Misc.pm b/Misc.pm
index 6f923897b3c748edab1c84bd7246e68a2fbc0edc..a08ae7632f87cf096051b170302b4bb7ef5944ed 100644 (file)
--- a/Misc.pm
+++ b/Misc.pm
@@ -49,7 +49,7 @@ sub parseCommand {
        my ($p,$command,$args) = ($msg =~ /^([.!~])(\S+)(?: (.+))?/);
 
        if ($msg =~ m{http://[\w.]+/.+?scan(_id|_grp)?=(\w+)}){
-               unless ($command){
+               if (!$command || $command =~ m{^http://}){
                        ($p,$command,$args) = ('.','addscan',$msg);
                }elsif($command ne 'addscan'){
                        parseCommand (".addscan $msg", $server, $nick, $address, $channel, $disp,$model)