sub call_authenticate {
my $self = shift;
return $self->model_class->authenticate($self) if
- $self->model_class->can("authenticate");
- return $self->authenticate();
+ $self->model_class->can("authenticate");
+ return $self->authenticate($self); # Interface consistency is a Good Thing
}
sub additional_data {}
package ProductDatabase;
use base 'Maypole';
__PACKAGE__->set_database("dbi:mysql:products");
- BeerDB->config->{uri_base} = "http://your.site/catalogue/";
+ ProductDatabase->config->{uri_base} = "http://your.site/catalogue/";
ProductDatabase::Product->has_a("category" => ProductDatabase::Category);
# ...