Pluggable Tax: more POD, more tests, better code and less bugs
This commit is contained in:
parent
f3ed30d939
commit
461c80a6b8
7 changed files with 602 additions and 57 deletions
|
|
@ -105,6 +105,8 @@ sub className {
|
|||
my $self = shift;
|
||||
|
||||
$self->session->log->fatal( "Tax plugin ($self) is required to overload the className method" );
|
||||
|
||||
return 'WebGUI::Shop:TaxDriver';
|
||||
}
|
||||
|
||||
#-----------------------------------------------------------
|
||||
|
|
@ -214,6 +216,9 @@ sub new {
|
|||
my $class = shift;
|
||||
my $session = shift;
|
||||
|
||||
WebGUI::Error::InvalidObject->throw( expected => "WebGUI::Session", got => (ref $session), error => "Need a session." )
|
||||
unless $session && $session->isa( 'WebGUI::Session' );
|
||||
|
||||
my $self = {};
|
||||
bless $self, $class;
|
||||
register $self;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue