Use decent regex.
This commit is contained in:
1 parent
df401193dc
commit
29f00aba27
1 file changed
+3
-1
+3
-1
@@ -6,6 +6,7 @@ use strict;
|
|||||||
use warnings;
|
use warnings;
|
||||||
use API::Std qw(conf_get err awarn trans);
|
use API::Std qw(conf_get err awarn trans);
|
||||||
use API::IRC;
|
use API::IRC;
|
||||||
|
use Data::Dumper;
|
||||||
|
|
||||||
# Raw parsing hash.
|
# Raw parsing hash.
|
||||||
our %RAWC = (
|
our %RAWC = (
|
||||||
@@ -53,7 +54,8 @@ sub ircparse
|
|||||||
my ($svr, $data) = @_;
|
my ($svr, $data) = @_;
|
||||||
|
|
||||||
# Split spaces into @ex.
|
# Split spaces into @ex.
|
||||||
my @ex = split(' ', $data);
|
my @ex = split /\s+/, $data;
|
||||||
|
print Dumper(@ex);
|
||||||
|
|
||||||
# Make sure there is enough data.
|
# Make sure there is enough data.
|
||||||
if (defined $ex[0] and defined $ex[1]) {
|
if (defined $ex[0] and defined $ex[1]) {
|
||||||
|
|||||||
Reference in new issue
Block a user