summaryrefslogtreecommitdiffstats
path: root/lib/Bot
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2009-06-02 00:13:50 -0500
committerJesse Luehrs <doy@tozt.net>2009-06-02 00:13:50 -0500
commit77f7f5d362f5e1fa1d1d34936af9268778d99132 (patch)
tree9ea01aad34cab179bbb0907515835bfa7b8a89e7 /lib/Bot
parentd322e62631ca94b4aeae23f3898f4445f1275eb9 (diff)
downloadbot-games-77f7f5d362f5e1fa1d1d34936af9268778d99132.tar.gz
bot-games-77f7f5d362f5e1fa1d1d34936af9268778d99132.zip
s/$class/$caller/g
Diffstat (limited to 'lib/Bot')
-rw-r--r--lib/Bot/Games/OO/Game.pm10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/Bot/Games/OO/Game.pm b/lib/Bot/Games/OO/Game.pm
index 218eb32..5820b80 100644
--- a/lib/Bot/Games/OO/Game.pm
+++ b/lib/Bot/Games/OO/Game.pm
@@ -2,15 +2,15 @@ package Bot::Games::OO::Game;
use Bot::Games::OO ();
sub command {
- my $class = shift;
+ my $caller = shift;
my $name = shift;
my $code;
$code = shift if ref($_[0]) eq 'CODE';
my %args = @_;
- my $method_meta = $class->meta->get_method($name);
+ my $method_meta = $caller->meta->get_method($name);
my $superclass = Moose::blessed($method_meta)
- || $class->meta->method_metaclass;
+ || $caller->meta->method_metaclass;
my @method_metaclass_roles = ('Bot::Games::Trait::Method::Command');
push @method_metaclass_roles, 'Bot::Games::Trait::Method::Formatted'
if $args{formatter};
@@ -25,10 +25,10 @@ sub command {
else {
$method_meta = $method_metaclass->name->wrap(
$code,
- package_name => $class,
+ package_name => $caller,
name => $name,
);
- $class->meta->add_method($name, $method_meta);
+ $caller->meta->add_method($name, $method_meta);
}
for my $attr (map { $_->meta->get_attribute_list } @method_metaclass_roles) {
next unless exists $args{$attr};