mirror of
https://github.com/pragma-/pbot.git
synced 2024-11-29 23:39:24 +01:00
Replaced ".*" with "global" in set/unset; replaced "," with ";" as comma
This commit is contained in:
parent
d7f2583aac
commit
322314d869
@ -270,7 +270,7 @@ sub set {
|
|||||||
my $comma = '';
|
my $comma = '';
|
||||||
foreach my $key (sort keys %{ $self->hash->{$primary}->{$secondary} }) {
|
foreach my $key (sort keys %{ $self->hash->{$primary}->{$secondary} }) {
|
||||||
$result .= $comma . "$key => " . $self->hash->{$primary}->{$secondary}->{$key};
|
$result .= $comma . "$key => " . $self->hash->{$primary}->{$secondary}->{$key};
|
||||||
$comma = ", ";
|
$comma = "; ";
|
||||||
}
|
}
|
||||||
$result .= "none" if($comma eq '');
|
$result .= "none" if($comma eq '');
|
||||||
return $result;
|
return $result;
|
||||||
@ -283,6 +283,7 @@ sub set {
|
|||||||
$self->save();
|
$self->save();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$primary = 'global' if $primary eq '.*';
|
||||||
return "[$self->{name}] ($primary) $secondary: '$key' " . (defined $value ? "set to '$value'" : "is not set.");
|
return "[$self->{name}] ($primary) $secondary: '$key' " . (defined $value ? "set to '$value'" : "is not set.");
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -308,6 +309,7 @@ sub unset {
|
|||||||
delete $self->hash->{$primary}->{$secondary}->{$key};
|
delete $self->hash->{$primary}->{$secondary}->{$key};
|
||||||
$self->save();
|
$self->save();
|
||||||
|
|
||||||
|
$primary = 'global' if $primary eq '.*';
|
||||||
return "[$self->{name}] ($primary) $secondary: '$key' unset.";
|
return "[$self->{name}] ($primary) $secondary: '$key' unset.";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -221,7 +221,7 @@ sub set {
|
|||||||
my $comma = '';
|
my $comma = '';
|
||||||
foreach my $k (sort keys %{ $self->hash->{$hash_index} }) {
|
foreach my $k (sort keys %{ $self->hash->{$hash_index} }) {
|
||||||
$result .= $comma . "$k => " . $self->hash->{$hash_index}{$k};
|
$result .= $comma . "$k => " . $self->hash->{$hash_index}{$k};
|
||||||
$comma = ", ";
|
$comma = "; ";
|
||||||
}
|
}
|
||||||
$result .= "none" if($comma eq '');
|
$result .= "none" if($comma eq '');
|
||||||
return $result;
|
return $result;
|
||||||
|
@ -13,7 +13,7 @@ use warnings;
|
|||||||
# These are set automatically by the build/commit script
|
# These are set automatically by the build/commit script
|
||||||
use constant {
|
use constant {
|
||||||
BUILD_NAME => "PBot",
|
BUILD_NAME => "PBot",
|
||||||
BUILD_REVISION => 215,
|
BUILD_REVISION => 216,
|
||||||
BUILD_DATE => "2010-06-29",
|
BUILD_DATE => "2010-06-29",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user