fix namespace for dbh
This commit is contained in:
parent
2548ec3bc0
commit
e7c337f9f3
|
@ -80,10 +80,10 @@ sub load {
|
|||
my $type = ref $self;
|
||||
if ( ! $data ) {
|
||||
#$log->debug("Object::load Loading from db $type");
|
||||
$data = $ZoneMinder::dbh->selectrow_hashref( 'SELECT * FROM Storage WHERE Id=?', {}, $$self{Id} );
|
||||
$data = $ZoneMinder::Database::dbh->selectrow_hashref( 'SELECT * FROM Storage WHERE Id=?', {}, $$self{Id} );
|
||||
if ( ! $data ) {
|
||||
if ( $ZoneMinder::dbh->errstr ) {
|
||||
Error( "Failure to load Storage record for $$self{id}: Reason: " . $ZoneMinder::dbh->errstr );
|
||||
if ( $ZoneMinder::Database::dbh->errstr ) {
|
||||
Error( "Failure to load Storage record for $$self{id}: Reason: " . $ZoneMinder::Database::dbh->errstr );
|
||||
} # end if
|
||||
} # end if
|
||||
} # end if ! $data
|
||||
|
|
Loading…
Reference in New Issue