From: David Kamholz Date: Sun, 12 Feb 2006 14:53:38 +0000 (+0000) Subject: don't die if result_source_instance is not available on thaw in Serialize::Storable X-Git-Tag: v0.06000~61^2~36 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=cba990942db66fe6599146f55e21b6bd692eb90f;p=dbsrgits%2FDBIx-Class.git don't die if result_source_instance is not available on thaw in Serialize::Storable --- diff --git a/lib/DBIx/Class/Serialize/Storable.pm b/lib/DBIx/Class/Serialize/Storable.pm index 48c4597..8066337 100644 --- a/lib/DBIx/Class/Serialize/Storable.pm +++ b/lib/DBIx/Class/Serialize/Storable.pm @@ -12,7 +12,7 @@ sub STORABLE_freeze { sub STORABLE_thaw { my ($self,$cloning,$serialized) = @_; %$self = %{ Storable::thaw($serialized) }; - $self->result_source($self->result_source_instance); + $self->result_source($self->result_source_instance) if $self->can('result_source_instance'); } 1;