my ($self, $myconfig) = @_;
# connect to database
- my $dbh = SL::DBConnect->connect($myconfig->{dbconnect}, $myconfig->{dbuser}, $myconfig->{dbpasswd}, SL::DBConnect->get_options)
- or $self->dberror;
+ my $dbh = SL::DBConnect->connect or $self->dberror;
# set db options
if ($myconfig->{dboptions}) {
my ($self, $myconfig) = @_;
# connect to database
- my $dbh = SL::DBConnect->connect($myconfig->{dbconnect}, $myconfig->{dbuser}, $myconfig->{dbpasswd}, SL::DBConnect->get_options(AutoCommit => 0))
- or $self->dberror;
+ my $dbh = SL::DBConnect->connect(SL::DBConnect->get_connect_args(AutoCommit => 0)) or $self->dberror;
# set db options
if ($myconfig->{dboptions}) {