}
sub setHost {
- my ($nick, $host) = @_;
- DB();
+ my ($msg, $command) = @_;
+
+ my ($nick, $host);
+ if(defined $msg && $msg =~ /^(\S+) (\S+)$/){
+ $nick = $1;
+ $host = $2;
+ }else{
+ $ND::server->command("notice $ND::nick syntax: .sethost nick host | % can be used for wildcards \%arro% will match barrow");
+ return;
+ }
if (hc()){
my $f = $ND::DBH->prepare("SELECT uid,username FROM users WHERE username ILIKE ?");
$f->execute($nick);