From 4a8ab2afa9c10f473812f7aaf60582ba2629bcda Mon Sep 17 00:00:00 2001 From: Simon Green Date: Fri, 13 Sep 2013 09:39:43 +1000 Subject: Bug 914986 - Create Bug.update_attachment to update attachments via RPC/REST r=dkl, a=sgreen --- Bugzilla/Attachment.pm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'Bugzilla/Attachment.pm') diff --git a/Bugzilla/Attachment.pm b/Bugzilla/Attachment.pm index 251363c35..92e05e606 100644 --- a/Bugzilla/Attachment.pm +++ b/Bugzilla/Attachment.pm @@ -900,10 +900,11 @@ sub update { } if (scalar(keys %$changes)) { - $dbh->do('UPDATE attachments SET modification_time = ? WHERE attach_id = ?', - undef, ($timestamp, $self->id)); - $dbh->do('UPDATE bugs SET delta_ts = ? WHERE bug_id = ?', - undef, ($timestamp, $self->bug_id)); + $dbh->do('UPDATE attachments SET modification_time = ? WHERE attach_id = ?', + undef, ($timestamp, $self->id)); + $dbh->do('UPDATE bugs SET delta_ts = ? WHERE bug_id = ?', + undef, ($timestamp, $self->bug_id)); + $self->{modification_time} = $timestamp; } return $changes; -- cgit v1.2.3-24-g4f1b