Bug 28306: Fix POD

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Kyle M Hall 2021-07-23 15:19:30 -04:00 committed by Jonathan Druart
parent 1c115fcff7
commit 57e95681d4
1 changed files with 17 additions and 4 deletions

View File

@ -37,12 +37,25 @@ use Koha::Config;
our $database;
# FIXME: It is useless to have a Koha::Database object since all methods
# below act as class methods
# Koha::Database->new->schema is exactly the same as Koha::Database->schema
# We should use Koha::Database->schema everywhere and remove the `new` method
=head2 new
$schema = Koha::Database->new->schema;
FIXME: It is useless to have a Koha::Database object since all methods
below act as class methods
Koha::Database->new->schema is exactly the same as Koha::Database->schema
We should use Koha::Database->schema everywhere and remove the `new` method
=cut
sub new { bless {}, shift }
=head2 dbh
Returns a database handler without loading the DBIx::Class schema.
=cut
sub dbh {
my $config = Koha::Config->get_instance;
my $driver = db_scheme2dbi($config->get('db_scheme'));