3
0
mirror of https://github.com/pragma-/pbot.git synced 2024-10-01 17:16:39 +02:00

Remove NewModule.pm skeleton file

This commit is contained in:
Pragmatic Software 2010-06-05 04:41:37 +00:00
parent b1c2a12500
commit 7df2346d01
2 changed files with 1 additions and 44 deletions

View File

@ -1,43 +0,0 @@
# File: NewModule.pm
# Author: pragma_
#
# Purpose: New module skeleton
package PBot::NewModule;
use warnings;
use strict;
use vars qw($VERSION);
$VERSION = $PBot::PBot::VERSION;
use Carp ();
sub new {
if(ref($_[1]) eq 'HASH') {
Carp::croak("Options to Logger should be key/value pairs, not hash reference");
}
my ($class, %conf) = @_;
my $self = bless {}, $class;
$self->initialize(%conf);
return $self;
}
sub initialize {
my ($self, %conf) = @_;
my $option = delete $conf{option};
$option = 10 unless defined $option; # set to default value unless defined
if(defined $option) {
# do something (optional)
}
$self->{option} = $option;
}
# subs here
1;

View File

@ -13,7 +13,7 @@ use warnings;
# These are set automatically by the build/commit script
use constant {
BUILD_NAME => "PBot",
BUILD_REVISION => 141,
BUILD_REVISION => 142,
BUILD_DATE => "2010-06-04",
};