[vhffs-dev] [1526] encoding descriptions into utf8, fixed accept and refuse regexp |
[ Thread Index |
Date Index
| More vhffs.org/vhffs-dev Archives
]
Revision: 1526
Author: gradator
Date: 2009-11-22 14:49:36 +0100 (Sun, 22 Nov 2009)
Log Message:
-----------
encoding descriptions into utf8, fixed accept and refuse regexp
Modified Paths:
--------------
trunk/vhffs-irc/modobot.pl
Modified: trunk/vhffs-irc/modobot.pl
===================================================================
--- trunk/vhffs-irc/modobot.pl 2009-11-06 23:30:34 UTC (rev 1525)
+++ trunk/vhffs-irc/modobot.pl 2009-11-22 13:49:36 UTC (rev 1526)
@@ -349,7 +349,7 @@
my @text = split (/\n/, $wrapper->wrap($text));
while ($text = shift @text)
{
- $bot->privmsg($chan, $text);
+ $bot->privmsg($chan, Encode::encode_utf8($text) );
sleep 2;
sleep 8 if (($cmpt%10) == 9);
$cmpt++;
@@ -370,7 +370,7 @@
my $oid = $texte;
my $raison = $texte;
Vhffs::Main::current_user_uid($user->get_uid);
- $raison =~ s/^${mynick}: accept [0-9]+ //;
+ $raison =~ s/^${mynick}: accept [0-9]+ *//;
$oid =~ s/^${mynick}: accept ([0-9]+).*$/$1/;
moderate( $oid , 1 , $raison);
}
@@ -381,7 +381,7 @@
my $oid = $texte;
my $raison = $texte;
Vhffs::Main::current_user_uid($user->get_uid);
- $raison =~ s/^${mynick}: refuse [0-9]+ //;
+ $raison =~ s/^${mynick}: refuse [0-9]+ +//;
$oid =~ s/^${mynick}: refuse ([0-9]+) .*$/$1/;
moderate( $oid , 0 , $raison);
}