From: dms Date: Sun, 3 Nov 2002 14:20:05 +0000 (+0000) Subject: - added user flag +a for asking factoids... X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=a331d31cfe5c3b98b2284b44ce4e7a755443e803;p=infobot.git - added user flag +a for asking factoids... I'm surprised this does not even exist in infobot... weird. git-svn-id: https://svn.code.sf.net/p/infobot/code/trunk/blootbot@597 c11ca15a-4712-0410-83d8-924469b57eb5 --- diff --git a/src/Factoids/Question.pl b/src/Factoids/Question.pl index 2c1a6e5..347e5d6 100644 --- a/src/Factoids/Question.pl +++ b/src/Factoids/Question.pl @@ -38,6 +38,13 @@ sub doQuestion { } else { ### TODO: this should be caught in Process.pl? return '' unless ($talkok); + + # there is no flag to disable/enable asking factoids... + # so it was added... thanks zyxep! :) + if (&IsFlag("a") ne "a") { + &status("$who tried to ask us when not allowed."); + return; + } } # dangerous; common preambles should be stripped before here