From 4dc6c98c155a72be277a6424330359c139381ee7 Mon Sep 17 00:00:00 2001 From: dms Date: Fri, 9 Feb 2001 13:40:01 +0000 Subject: [PATCH] changed FlatArg to ArrayArgs to make more sense. by default, we use flat-args git-svn-id: https://svn.code.sf.net/p/infobot/code/trunk@371 c11ca15a-4712-0410-83d8-924469b57eb5 --- blootbot/src/CommandStubs.pl | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/blootbot/src/CommandStubs.pl b/blootbot/src/CommandStubs.pl index c942c9d..7166b6f 100644 --- a/blootbot/src/CommandStubs.pl +++ b/blootbot/src/CommandStubs.pl @@ -95,7 +95,7 @@ sub parseCmdHook { if (exists $hash{'Forker'}) { $hash{'Identifier'} .= "-" if ($hash{'Forker'} eq "NULL"); - if (exists $hash{'FlatArg'} and $hash{'FlatArg'} == 0) { + if (exists $hash{'ArrayArgs'}) { &Forker($hash{'Identifier'}, sub { \&{$hash{'CODEREF'}}(@args) } ); } else { &Forker($hash{'Identifier'}, sub { \&{$hash{'CODEREF'}}($flatarg) } ); @@ -108,8 +108,7 @@ sub parseCmdHook { ### TODO: check if CODEREF exists. - if (exists $hash{'FlatArg'} and $hash{'FlatArg'} == 0) { - &status("CmdHook: using args as array."); + if (exists $hash{'ArrayArgs'}) { &{$hash{'CODEREF'}}(@args); } else { &{$hash{'CODEREF'}}($flatarg); -- 2.39.5