On Wed, Feb 02, 2000 at 08:21:20PM +0200, Stas Bekman wrote:
>

Oh, and while I'm being picky (nothing personal Stas!):

>   $self->{sth}->finish     if defined $self->{sth} and $self->{sth};
>   $self->{dbh}->disconnect if defined $self->{dbh} and $self->{dbh};

There's no need to test for "defined" and "true" since undefined is false
and won't generate a warning when used in a boolean context. Thus just:

    $self->{sth}->finish     if $self->{sth};
    $self->{dbh}->disconnect if $self->{dbh};

Tim:

Reply via email to