From: Matt S Trout Date: Sat, 11 Feb 2006 17:04:44 +0000 (+0000) Subject: Made discard_changes use ->result_source->resultset->find X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=b653de5d3898f4c4d6bd65d9ee6c814159d50551;p=dbsrgits%2FDBIx-Class-Historic.git Made discard_changes use ->result_source->resultset->find --- diff --git a/lib/DBIx/Class/PK.pm b/lib/DBIx/Class/PK.pm index 4c8f106..23d2b3c 100644 --- a/lib/DBIx/Class/PK.pm +++ b/lib/DBIx/Class/PK.pm @@ -41,7 +41,7 @@ sub discard_changes { my ($self) = @_; delete $self->{_dirty_columns}; return unless $self->in_storage; # Don't reload if we aren't real! - my ($reload) = $self->find(map { $self->$_ } $self->primary_columns); + my ($reload) = $self->result_source->resultset->find(map { $self->$_ } $self->primary_columns); unless ($reload) { # If we got deleted in the mean-time $self->in_storage(0); return $self;