From: dms Date: Sun, 24 Sep 2000 11:51:21 +0000 (+0000) Subject: moved a few lines from CommandStubs.pl here X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=f985d771e7d7fbdca69b46dd9ceb96a0c260b458;p=infobot.git moved a few lines from CommandStubs.pl here git-svn-id: https://svn.code.sf.net/p/infobot/code/trunk/blootbot@139 c11ca15a-4712-0410-83d8-924469b57eb5 --- diff --git a/src/Modules/Dict.pl b/src/Modules/Dict.pl index 3e613a5..1450107 100644 --- a/src/Modules/Dict.pl +++ b/src/Modules/Dict.pl @@ -1,7 +1,7 @@ # # Dict.pl: Frontend to dict.org. # Author: dms -# Version: v0.6b (19991224). +# Version: v0.6c (20000924). # Created: 19990914. # @@ -22,6 +22,12 @@ sub Dict { my $socket = new IO::Socket; my @results; + for ($query) { + s/^[\s\t]+//; + s/[\s\t]+$//; + s/[\s\t]+/ /; + } + # connect. socket($socket, PF_INET, SOCK_STREAM, $proto) or return "error: socket: $!"; eval {