Commit f4027326 authored by Leo Gordon's avatar Leo Gordon
Browse files

update the status in the object first, and then only store the change if possible

parent e1735148
......@@ -210,15 +210,19 @@ sub refresh {
sub update {
my $self = shift;
return unless($self->adaptor);
$self->adaptor->update($self);
if($self->adaptor) {
$self->adaptor->update($self);
}
}
sub update_status {
my ($self, $status ) = @_;
return unless($self->adaptor);
$self->adaptor->update_status($self->analysis_id, $status);
$self->status($status);
if($self->adaptor) {
$self->adaptor->update_status($self->analysis_id, $status);
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment