ODBC fixes: superfluous connection in rebless; undef PK on first insert in MSSQL
[dbsrgits/DBIx-Class.git] / lib / DBIx / Class / Storage / DBI / ODBC.pm
index d7b4509..16e198e 100644 (file)
@@ -7,8 +7,7 @@ use base qw/DBIx::Class::Storage::DBI/;
 sub _rebless {
     my ($self) = @_;
 
-    my $dbh = $self->dbh;
-    my $dbtype = eval { $dbh->get_info(17) };
+    my $dbtype = eval { $self->_dbh->get_info(17) };
     unless ( $@ ) {
         # Translate the backend name into a perl identifier
         $dbtype =~ s/\W/_/gi;