From: Rafael Kitover Date: Sat, 13 Jun 2009 15:31:52 +0000 (+0000) Subject: allow undef for _setup_connect_do X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=7a85eeb378989836ef3955cc75168a213f0485e2;p=dbsrgits%2FDBIx-Class-Historic.git allow undef for _setup_connect_do --- diff --git a/lib/DBIx/Class/Storage/DBI.pm b/lib/DBIx/Class/Storage/DBI.pm index a049167..26fcbbb 100644 --- a/lib/DBIx/Class/Storage/DBI.pm +++ b/lib/DBIx/Class/Storage/DBI.pm @@ -478,8 +478,11 @@ sub _setup_connect_do { my $val = shift; - $self->throw_exception("The value of $opt cannot be 'undef'") - unless defined $val; + if (not defined $val) { + $self->$accessor(undef); + $self->$store(undef); + return; + } my @store;